When is a quote not a quote? 
Author Message
 When is a quote not a quote?

On Thu, 12 Mar 1998 07:27:07 -0800, "William M. Klein"

Quote:

>Would
>you like a new figurative constant (e.g. APOSTROPHE) to represent the single
>quote?

hmm. it would be nice to have APOS as num 39(34?)
but apostrophe is a hard word to spell.




Sun, 27 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?

I would like to get some input (hear some feedback) from this newsgroup on
an issue related to the draft of the next COBOL Standard.

In the next Standard, it will (finally) be legal to use either a "double
quote" or a 'single quote' (aka apostrophe) around alphanumeric literals.
(Almost every compiler that I know of has had this ability since key punch
machines or when the compiler was first released - but that is another
issue.) The draft Standard allows the two to be mixed in the same program
but not for the same literal (as is allowed in some but not all existing
compilers that allow single quotes at all.)

HOWEVER, the draft Standard requires that the figurative constant QUOTE
*always* represent the "double quote" variation.

My question is whether you think that this is a real problem or not? Would
you like there to be a way to control this (options that exist today that I
know of include compiler options/directives or special-names phrases). Would
you like a new figurative constant (e.g. APOSTROPHE) to represent the single
quote?

or Generally, don't you care what the draft does about this?

--
+ +
+   Bill Klein -
         "C" is a nice letter to START the name of your programming language
with
      but I wouldn't want to end up there.



Mon, 28 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?

Quote:

> My question is whether you think that this is a real problem or not? Would
> you like there to be a way to control this (options that exist today that I
> know of include compiler options/directives or special-names phrases). Would
> you like a new figurative constant (e.g. APOSTROPHE) to represent the single
> quote?

> or Generally, don't you care what the draft does about this?

I have used the "QUOTE" quite often - but only because I was using a
compiler that needed the double quotes and not the apostrophes.  

The problem cam in when the Apost was used instead of the Quote - heck
for years I thought the "double quote" was wrong.

Say you wanted something to be this:  That's my name.

With the apost usage you could not do it easily.  'That's my name.'
would {*filter*}the compiler.  "That's my name" works fine, but you have to
use quotes everywhere currently.  

I'm getting to the point - bear with me.

The new standard that allows mixing, but not on the same litterals would
solve both problems - almost.

You could say '"Drat", he said' or
              "That's mine"
 but not:
            '"Drat", he said, "That's mine"'

It would {*filter*}on that.  Having QUOTE works well for stringing and
unstringing comma quote delimited files, but would not solve the above.

The above is solveable by using multiple literals and stringing them
together, even without the APOST word, having QUOTE is sufficient.

To allow one full freedom, it would be nice to have an APOST and a
QUOTE, but it will be better than present the way it is newly defined.

Answer: Don't care.



Mon, 28 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?

Quote:

> snipped
> HOWEVER, the draft Standard requires that the figurative constant QUOTE
> *always* represent the "double quote" variation.

> My question is whether you think that this is a real problem or not? Would
> you like there to be a way to control this (options that exist today that I
> know of include compiler options/directives or special-names phrases). Would
> you like a new figurative constant (e.g. APOSTROPHE) to represent the single
> quote?

> or Generally, don't you care what the draft does about this?

Before you respond, be aware that the proposed standard allows literals
to be concatenated.  Why would one need APOSTROPHE (or QUOTE for that
matter)?  Of course, using the word QUOTE in creating a literal string
made little sense anyhow.  For things like delimiters it was always just
as easy to say """" instead of QUOTE using standard terminology.

   'Porky said "That' & "'s all folks" & '".'

Gee - it looks almost like C!

--
Don Nelson
COBOL Development, Tandem Computers, Inc.
Member, NCITS J4 and ISO/IEC JTC1/SC22 WG4 COBOL Committees

No clever quotes here



Mon, 28 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?

[cut to the chase]

Quote:
> HOWEVER, the draft Standard requires that the figurative constant QUOTE
> *always* represent the "double quote" variation.

> My question is whether you think that this is a real problem or not?

... as opposed to a 'fake problem'?  No matter *what* the change is some
folks'll like it, some'll whine, urinate and moan... as they say in
Latin, 'ayn chadash tachat hashemesh'.  Me, personally, I am so used to
single-quotes that you'll notice I use them all the doo-dah day... but I
am sure that somewhere, in the bowels of a Very Important System, that
Mission-Ctitical Code depends on the reserved-word QUOTE producing a
'... and I'm sure there is a Very Good Reason for it, too.

DD



Mon, 28 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?



Quote:
> I would like to get some input (hear some feedback) from this newsgroup
on
> an issue related to the draft of the next COBOL Standard.

> In the next Standard, it will (finally) be legal to use either a "double
> quote" or a 'single quote' (aka apostrophe) around alphanumeric literals.
> (Almost every compiler that I know of has had this ability since key
punch
> machines or when the compiler was first released - but that is another
> issue.) The draft Standard allows the two to be mixed in the same program
> but not for the same literal (as is allowed in some but not all existing
> compilers that allow single quotes at all.)

> HOWEVER, the draft Standard requires that the figurative constant QUOTE
> *always* represent the "double quote" variation.

> My question is whether you think that this is a real problem or not?
Would
> you like there to be a way to control this (options that exist today that
I
> know of include compiler options/directives or special-names phrases).
Would
> you like a new figurative constant (e.g. APOSTROPHE) to represent the
single
> quote?

I think there would be a problem if QUOTE were not consistant.  Otherwise,
the results of the program would change from it's original intent based
upon a compiler/installation option.  APOSTROPHE would be okay, but not
necessary.

- Show quoted text -

Quote:

> or Generally, don't you care what the draft does about this?

> --
> + +
> +   Bill Klein -
>          "C" is a nice letter to START the name of your programming
language
> with
>       but I wouldn't want to end up there.



Mon, 28 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?

On Thu, 12 Mar 1998 07:27:07 -0800, "William M. Klein"

Quote:

>I would like to get some input (hear some feedback) from this newsgroup on
>an issue related to the draft of the next COBOL Standard.

>In the next Standard, it will (finally) be legal to use either a "double
>quote" or a 'single quote' (aka apostrophe) around alphanumeric literals.
>(Almost every compiler that I know of has had this ability since key punch
>machines or when the compiler was first released - but that is another
>issue.) The draft Standard allows the two to be mixed in the same program
>but not for the same literal (as is allowed in some but not all existing
>compilers that allow single quotes at all.)

>HOWEVER, the draft Standard requires that the figurative constant QUOTE
>*always* represent the "double quote" variation.

>My question is whether you think that this is a real problem or not? Would
>you like there to be a way to control this (options that exist today that I
>know of include compiler options/directives or special-names phrases). Would
>you like a new figurative constant (e.g. APOSTROPHE) to represent the single
>quote?

>or Generally, don't you care what the draft does about this?

It could be a problem.  Apostrophe was the standard for so long that
most programs still use it.  So you'll usually find that "Quote" means
apostrophe.  In fact I know in CICS "Quote" stands for some screen
attribute.  So if you're right about this standard it might break a
lot of programs.
---------------------------------------------------------------
Ever Notice....

....how quickly "pay later" comes when you "buy now"?
....the weaker the arguments, the stronger the words?
....the first piece of luggage out of the airport baggage chute never belongs to anybody?
....the shortest line becomes the slowest line once you choose it?
....the last key in the bunch usually opens the lock?
....the first person to get off a crowded eleveator is always standing in the back?
....immediately after you buy an item, you find a coupon for it?



Tue, 29 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?



Quote:
>Before you respond, be aware that the proposed standard allows literals
>to be concatenated.  Why would one need APOSTROPHE (or QUOTE for that
>matter)?  Of course, using the word QUOTE in creating a literal string
>made little sense anyhow.  For things like delimiters it was always just
>as easy to say """" instead of QUOTE using standard terminology.

>   'Porky said "That' & "'s all folks" & '".'

---------------------------------------------------------------
Ever Notice....

....how quickly "pay later" comes when you "buy now"?
....the weaker the arguments, the stronger the words?
....the first piece of luggage out of the airport baggage chute never belongs to anybody?
....the shortest line becomes the slowest line once you choose it?
....the last key in the bunch usually opens the lock?
....the first person to get off a crowded eleveator is always standing in the back?
....immediately after you buy an item, you find a coupon for it?



Tue, 29 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?



Quote:
>Before you respond, be aware that the proposed standard allows literals
>to be concatenated.  Why would one need APOSTROPHE (or QUOTE for that
>matter)?  Of course, using the word QUOTE in creating a literal string
>made little sense anyhow.  For things like delimiters it was always just
>as easy to say """" instead of QUOTE using standard terminology.

>   'Porky said "That' & "'s all folks" & '".'

>Gee - it looks almost like C!

You're right, it's just as unreadable.  What were you and the
committee smoking the day you came up with this gem?
---------------------------------------------------------------
Ever Notice....

....how quickly "pay later" comes when you "buy now"?
....the weaker the arguments, the stronger the words?
....the first piece of luggage out of the airport baggage chute never belongs to anybody?
....the shortest line becomes the slowest line once you choose it?
....the last key in the bunch usually opens the lock?
....the first person to get off a crowded eleveator is always standing in the back?
....immediately after you buy an item, you find a coupon for it?



Tue, 29 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?

8<

Quote:
> >   'Porky said "That' & "'s all folks" & '".'

> >Gee - it looks almost like C!

> You're right, it's just as unreadable.  What were you and the
> committee smoking the day you came up with this gem?

I can read that. Works just like rexx.

Cobol Frog



Tue, 29 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?

Quote:



> >Before you respond, be aware that the proposed standard allows literals
> >to be concatenated.  Why would one need APOSTROPHE (or QUOTE for that
> >matter)?  Of course, using the word QUOTE in creating a literal string
> >made little sense anyhow.  For things like delimiters it was always just
> >as easy to say """" instead of QUOTE using standard terminology.

> >   'Porky said "That' & "'s all folks" & '".'

Besides, those compiler vendors that allowed ' i.s.o. " (by specifying compile options) say
in their manuals that the figurative constant QUOTE(s) acts in accordance with the choosen
option. So the ones that really used the ' and the word QUOTE in their sources can (and will)
continue to do so. Almost nobody would like to mix usage of ' and " except in (rarely used)
porky-like constructs, where it will behave well-defined.

Implement it, I say!

2000 Cobol Frog(s)

[sig snip]



Tue, 29 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?

Quote:



> >Before you respond, be aware that the proposed standard allows literals
> >to be concatenated.  Why would one need APOSTROPHE (or QUOTE for that
> >matter)?  Of course, using the word QUOTE in creating a literal string
> >made little sense anyhow.  For things like delimiters it was always just
> >as easy to say """" instead of QUOTE using standard terminology.

> >   'Porky said "That' & "'s all folks" & '".'

> >Gee - it looks almost like C!

> You're right, it's just as unreadable.  What were you and the
> committee smoking the day you came up with this gem?

... possibly some very well-aged stuff that caused some *other*
committee to come up with (COND,5,LT)?

DD



Tue, 29 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?

Quote:

> >as easy to say """" instead of QUOTE using standard terminology.

> >   'Porky said "That' & "'s all folks" & '".'

> >Gee - it looks almost like C!

> You're right, it's just as unreadable.  What were you and the
> committee smoking the day you came up with this gem?

Good stuff!  Actually, though, literal concatenation is a very good
thing.  For instance, it is a zillion times easier than trying to
continue a literal across lines.  It is just that you can write some
strange constructs with it.

--
Don Nelson
COBOL Development, Tandem Computers, Inc.
Member, NCITS J4 and ISO/IEC JTC1/SC22 WG4 COBOL Committees

No clever quotes here



Tue, 29 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?

Quote:
> It could be a problem.  Apostrophe was the standard for so long

It was never in any standard.  It started as an IBM extension back in
the 60s or 70s.

Quote:
>that
> most programs still use it.  So you'll usually find that "Quote" means
> apostrophe.  In fact I know in CICS "Quote" stands for some screen
> attribute.  So if you're right about this standard it might break a
> lot of programs.

It won't break anything.  The single quote was an extension.  All
previous standards said explicity that the quote was a quote, not an
apostrophe.  What would break programs is a vendor who had the
apostrophe extension and took it away.  I assume those vendors who had
such an extension will continue to support is as a non-standard
extension.

--
Don Nelson
COBOL Development, Tandem Computers, Inc.
Member, NCITS J4 and ISO/IEC JTC1/SC22 WG4 COBOL Committees

No clever quotes here



Tue, 29 Aug 2000 03:00:00 GMT  
 When is a quote not a quote?

Quote:

>> It could be a problem.  Apostrophe was the standard for so long

 >snippage<

Quote:

>It won't break anything.  The single quote was an extension.  All
>previous standards said explicity that the quote was a quote, not an
>apostrophe.  What would break programs is a vendor who had the
>apostrophe extension and took it away.  I assume those vendors who had
>such an extension will continue to support is as a non-standard
>extension.

>-

  > more snippage< -

Actually, it will "break programs" if users think that because they can now
use the single-quote (apostrophe) as a literal delimeter, that they won't
need to use any extension.  The example given by the user is an excellent
example.  The QUOTE figurative constant appears in some vendor-supplied (IBM
in this case) COPYBOOKs in the VALUE clause of a field used as an attribute
byte. With the previous extension-implementation, this copybook was ONLy
used when the APOST (extension) compiler option was used - and this was easy
to veryify because other VALUE clauses would "fail" because they used
'literal' format VALUE clauses.  Now, however, these other VALUE clauses
will work fine (because the draft allows the use of apostrophe and quote as
delimiters in the same program) and the VALUE QUOTE will compile just fine
as well - it will just cause radically different (i.e. "program is broken")
run-time results.

All of this is "fixable" by the programmer - but only after the program has
failed and their perception will be that the new Standard has caused it.
That perception could easily be avoided if the draft Standard provided its
own solution to what the figuative constant QUOTE means.



Tue, 29 Aug 2000 03:00:00 GMT  
 
 [ 23 post ]  Go to page: [1] [2]

 Relevant Pages 

1. replace single quote to double quote with an example

2. quote quote reshape v

3. single-quoted string conversion to triple-quoted string

4. Quote.py - Look up stock quotes

5. Quote.py - Look up stock quotes

6. emacs python-mode quote in triple quote font-lock problem

7. I am in quoting hell

8. awk not printing single quotes

9. Multidimensional array not interpolated inside double quotes

10. I am not deaf, but am I mute?

11. REGULAR EXPRESSIONS; PERL/AWK/SED; SINGLE QUOTES/DOUBLE QUOTES

12. How do I quote an alias string that contains quotes itself? (ksh, awk)

 

 
Powered by phpBB® Forum Software