Changes between Version 8 and Version 9 of C
- Timestamp:
- 07/11/10 08:27:44 (14 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
C
v8 v9 29 29 * In resulting binaries such as .exe and .dll, the .NET standard CamelCase is used so that Cobra libraries vend out naturally to C# and VB.NET 30 30 * Class names must be (upper) [http://en.wikipedia.org/wiki/CamelCase CamelCased] or at least start with an upper case letter) 31 * instance variable optionally prefixed with _ (implicitly makes them private). If so prefixed can be accessed directly in methods 31 * instance variable optionally prefixed with _ (implicitly makes them protected) or __ (implicitly makes them private. 32 If so prefixed can be accessed directly in methods (without a leading '.') 32 33 * methods (and properties) on current object invoked with leading '''this.''' or more usually (shortcut) just '''.'''. 33 34 * constructor/initializer method is called init, has no return value 34 35 35 36 * String type accessed as '''String''' 36 * Numeric types specified as int, uint, float and double types ( 37 * Numeric types specified as int, uint, float and double types (rather than Int, UInt, Float, Double) 37 38 * Sized int and uint types all have the same naming form 38 39 * int8, int16, int/int32, int64 instead of SByte, Int16, Int32/int, Int64 … … 65 66 * 'Raw' Strings (r"a raw string") no escape sequence expansion ( vs c# @"a raw string") 66 67 * '!NoSubstitution' strings ( ns" no substitution [done] here") 67 * !DocStrings on Programs, classes, Instance variables, methods and properties68 * !DocStrings on Programs, Classes, Interfaces (etc), instance variables, methods and properties 68 69 * Different syntax for characters c'x' 69 $ since '[] used for Listsarray literals are specified using ''' @[]''' - comma separated values70 * '''ref''' keyword for getting pointer to method ( reference) rather calling it (for delegates)71 * '''sig''' keyword or declaring a delegate type70 * since '[] used for declaring literal Lists, array literals are specified using ''' @[]''' - comma separated values 71 * '''ref''' keyword for getting pointer to method (reference) rather than calling it (for delegates) 72 * '''sig''' keyword for declaring a delegate type 72 73 73 74 * '''def''' keyword to declare a method/function