This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 5462 - Can sml:nilref="true" be specified on a non-SML reference?
Summary: Can sml:nilref="true" be specified on a non-SML reference?
Status: RESOLVED FIXED
Alias: None
Product: SML
Classification: Unclassified
Component: Core (show other bugs)
Version: LC
Hardware: PC Windows XP
: P2 normal
Target Milestone: LC
Assignee: Virginia Smith
QA Contact: SML Working Group discussion list
URL:
Whiteboard:
Keywords: resolved
Depends on:
Blocks:
 
Reported: 2008-02-07 20:22 UTC by Sandy Gao
Modified: 2008-02-21 19:36 UTC (History)
0 users

See Also:


Attachments

Description Sandy Gao 2008-02-07 20:22:02 UTC
Related to bug 5408. Should SML allow the following?

<dummy sml:ref="false" slm:nilref="true"/>
Comment 1 Virginia Smith 2008-02-07 20:38:03 UTC
Resolution: allow but ignore sml:nilref and add "conforming processors MAY warn when ..."
Comment 2 Virginia Smith 2008-02-08 00:03:23 UTC
Section 4.2.5 now reads (last sentence is new):

4.2.5 Null SML References

An null SML reference is an explicit declaration of intent by the document author that the SML reference itself does not exist, and a processing directive (not a hint) to processors not to attempt to recognize any reference schemes in it. If an SML reference is recognized as null, then processors MUST NOT attempt to resolve it.

Processors MUST ignore an sml:nilref attribute when present on an element that is not an SML Reference [4.1.1 SML Reference], in which case the consumer MAY issue a warning to its invoker. 
Comment 3 Kumar Pandit 2008-02-13 08:08:22 UTC
+1 for the changes with one suggestion.

In the second para, the first half of the sentence uses 'processor' whereas the second half uses 'consumer'. Both parts should use the same word. I am ok with either processor or consumer in both locations.
Comment 4 John Arwe 2008-02-13 23:10:20 UTC
+1 http://www.w3.org/Bugs/Public/show_bug.cgi?id=5462#c3

and please change 
from: An null SML reference is an explicit 
to  : A  null SML reference is an explicit 
Comment 5 John Arwe 2008-02-13 23:29:24 UTC
Packaging this as a separate comment so it can be accepted/rejected separately of the preceding.

This text seems odd, like it is defining what something is by saying it is not its inverse.  "A null SML ref" sounds to me like it is a sub-class of all SML refs (confirmed by 4.1.1/4.1.2 SML editor's draft), yet the text appears to deny that when it says "the" SML ref does not exist.

An null SML reference is an explicit declaration of intent by the document
author that the SML reference itself does not exist,

I wonder if the following is clearer, especially since the rest of the text covers the corner cases now.  
from: that the               SML reference itself does not exist
to  : that the target of the SML reference        does not exist

The following text includes the earlier changes in comments 3 and 4.  For 3, I chose consumer since that is defined; last I looked we had no definition of a processor, and I see no value yet in adding one.

4.2.5 Null SML References

A null SML reference is an explicit declaration of intent by the document
author that the target of the SML reference does not exist, and a processing directive
(not a hint) to consumers not to attempt to recognize any reference schemes in
it. If an SML reference is recognized as null, then processors MUST NOT attempt
to resolve it.
Comment 6 John Arwe 2008-02-13 23:46:19 UTC
Packaging this as a separate comment so it can be accepted/rejected separately of the preceding.

4.2.5's new second paragraph
Processors MUST ignore an sml:nilref attribute when present on an element that
is not an SML Reference [4.1.1 SML Reference], in which case the consumer MAY
issue a warning to its invoker.

looks to me like another case of mixing syntax and semantics.  The syntax is discussed in 4.1.2, where any form of this probably belongs (since the definition of null SML reference depends on it being an SML ref via 4.1.2 condition 1, we currently have no name for an element such as <dummy sml:ref="false" slm:nilref="true"/> nor do I think we want to add one).

Secondly there is the email discussion about "must ignore" to deal with.  We need to either define 'processor' or change it (e.g. to model validator, since I see no more general term like SMLIF's "consumer"), that much seems clear.

As I understand Sandy's point, if "processor" or "model validator" is the hunk of software (current def says "embodiment"), then "MUST ignore" says for example that you don't find out that sml:ref="false" sml:nilref="fred" was specified even after schema validation runs. fred is not a legal boolean value, but it must not be checked because of the must-ignore.

PROPOSAL:
delete 4.2.5 paragraph 2 (see comment 2 for text)
add in 4.1.2, at the end, the following

It is a consequence of the preceding that this specification assigns no meaning to the sml:nilref attribute when it is used on an element that is not an SML reference.  Model validators MAY choose to warn their invokers should they detect this condition in a document.
Comment 7 Sandy Gao 2008-02-14 20:23:59 UTC
Sandy's comments mentioned in comment #6 can be found here:
http://lists.w3.org/Archives/Public/public-sml/2008Feb/0080.html

Also note that MSM typed in IRC the following when we discussed this issue:

  In 4.1.2 we could change 
    An element information item in an SML model instance document is
    an unresolved SML reference if and only if ...
  to 
    An SML reference in an SML model instance document is
    an unresolved SML reference if and only if ...
  I think we want this change whether we allow or we ignore the example in comment 0.
Comment 8 Virginia Smith 2008-02-14 22:09:12 UTC
Fixed per comments #4-7:

=> sections 4.1.2 and 4.1.3 changed from:
---------------------
4.1.2 Null SML Reference

An element information item in an SML model instance document is a null SML reference if and only if all of the following is true:

   1. It is an SML reference.
   2.  It has an attribute information item for which all of the following is true
         1. Its [local name] is nilref
         2. Its [namespace name] is http://www.w3.org/@@@@/@@/sml
         3. Its [normalized value] after whitespace normalization using collapse following schema rules, is either "true" or "1".

4.1.3 Unresolved SML Reference

An element information item in an SML model instance document is an unresolved SML reference if and only if all of the following is true:

   1. It is a non-null SML reference.
   2. None of the recognized reference schemes resolves.
...
--------------------
To:
----------------------
4.1.2 Null SML Reference

An SML reference is null if and only if it has an attribute information item for which all of the following is true

   1. Its [local name] is nilref
   2. Its [namespace name] is http://www.w3.org/@@@@/@@/sml
   3. Its [normalized value] after whitespace normalization using collapse following schema rules, is either "true" or "1".

It is a consequence of the preceding that this specification assigns no meaning to the sml:nilref attribute when it is used on an element that is not an SML reference. Model validators MAY choose to warn their invokers should they detect this condition in a document.

4.1.3 Unresolved SML Reference

An SML reference is unresolved if and only if all of the following is true:

   1. It is a non-null SML reference.
   2. None of the recognized reference schemes resolves.
...
------------------------

=> section 4.2.5 changed from:
-------------------
4.2.5 Null SML References

An null SML reference is an explicit declaration of intent by the document author that the SML reference itself does not exist, and a processing directive (not a hint) to model validators not to attempt to recognize any reference schemes in it. If an SML reference is recognized as null, then model validators MUST NOT attempt to resolve it.

Model validators MUST ignore an sml:nilref attribute when present on an element that is not an SML Reference [4.1.1 SML Reference], in which case the model validator MAY issue a warning to its invoker. 
--------------
To:
---------------------
4.2.5 Null SML References

A null SML reference is an explicit declaration of intent by the document author that the target of the SML reference does not exist and a processing directive (not a hint) to model validators not to attempt to recognize any reference schemes in it. If an SML reference is recognized as null, then model validators MUST NOT attempt to resolve it.

-------------------
Comment 9 Kirk Wilson 2008-02-16 14:54:46 UTC
+1 for the changes proposed in comment #8 
Comment 10 Kumar Pandit 2008-02-19 06:38:00 UTC
+1 for the changes described in comment #8 
Comment 11 John Arwe 2008-02-20 15:18:40 UTC
+1