Skip to content

andydevs69420/CScript-lang

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

92 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CScript-lang

cscript programming language prototype

Statements

  • import statement
  • var declairation
  • let declairation
  • if statement
  • for statement
  • while statement
  • do|while statement
  • switch|case statement
  • try/except/finally statement
  • print (print is a statement here.)
  • class declairation
  • continue statement
  • break statement
  • enum declairation
  • function declairation
  • function expression
  • statement block
  • expression statement

Datatype

  • CSObject(Hashmap based)
  • CSInteger
  • CSDouble
  • CSString
  • CSBoolean(to be re-implemented using singleton)
  • CSNullType(to be re-implemented using singleton)
  • CSArray
  • CSMap
  • CSCallable
  • CSClass
  • CSClassInstance
  • CSClassBoundMethod
  • CSBound
  • CSException
  • CSTypeError
  • CSAttributeError
  • CSIndexError

Other feature(s)

  • operator overloading(few)

TODO:

  • Rewrite evaluator|status:finished
  • fix grabage collector|status:fixed -> mark/sweep
  • fix try/except/finally
  • fix recursion error when str/toString|status:fixed
  • fix parser is confused with operator (+) and string "+"
    • example 2 "+" 2 = 4
                        ^^^ -- should error because string was used instead of (+).
    • status: fixed
  • add super capablility
  • fix adding bound