documentation: Breaking the API Reference documentation ice
[sdk] / doc / ecereCOM / char-pointer.econ
1 {
2    name = "char *",
3    description = "Core C 'char *' data type, mostly equivalent to the String data type. Ecere APIs taking a String or char * representing text expect UTF-8 encoding.",
4    usage = "Used in the declaration section of code, which is before any statements. \n"
5       "\n"
6       "A variable declared as being a char * can be assigned any literal string which is enclosed between double quotation marks (\" \").\n"
7       "\n"
8       "A key thing to remember is that the * is attached to the name of the variable, not the type.",
9    example = "char * thisString; // A stand alone declaration of a char *.\n"
10       "char * aString, * bString; // Declaring two char *s at the same time.\n"
11       "char * cString = \"Hello\", char * dString = \"World\"; // Declaring and initializing two chars and initializing them at the same time.\n"
12       "________________________________________\n"
13       "\n"
14       "class Hello : Application\n"
15       "{\n"
16       "   void Main()\n"
17       "   {\n"
18       "      char * helloString = \"Hello, World!\";\n"
19       "      printf(\"%s\\n\", helloString);\n"
20       "   }\n"
21       "}\n"
22       "\n"
23       "\n"
24       "\n"
25       "Output:\n"
26       "Hello, World!",
27    remarks = "char * is equivalent to char * in C.",
28    also = "bool, byte, char, double, enum, float, int, int64, uint, uint16, uint32, uint64"
29 }