Strings

Version 6 by jon_haslam
on Nov 27, 2007 07:45.

compared with
Current by jon_haslam
on Nov 27, 2007 07:46.

Key
This line was removed.
This word was removed. This word was added.
This line was added.

Changes (1)

View page history
h2. {anchor:CHP-STRINGS-2} String Constants
String constants are enclosed in double quotes ({{"}}) and are automatically assigned the type {{string}} by the D compiler. You can define string constants of any length, limited only by the amount of memory DTrace is permitted to consume on your system. The terminating null byte ({{\0}}) is added automatically by the D compiler to any string constants that you declare. The size of a string constant object is the number of bytes associated with the string plus one additional byte for the terminating null byte.\\
\\A string constant may not contain a literal newline character. To create strings containing newlines, use the {{\n}} escape sequence instead of a literal newline. String constants may also contain any of the special character escape sequences defined for character constants in [Table 2–5|types, operators and Expressions#TBL-ESCS].

[Top|#top]

The individuals who post here are part of the extended Sun Microsystems community and they might not be employed or in any way formally affiliated with Sun Microsystems. The opinions expressed here are their own, are not necessarily reviewed in advance by anyone but the individual authors, and neither Sun nor any other party necessarily agrees with them.

Copyright 1994-2009 Sun Microsystems, Inc.
Powered by Atlassian Confluence
Sun Guidelines on Public Discourse Privacy Policy Terms of Use Trademarks Site Map Employment Investor Relations Contact