Menu

New language add C#-style

testom
2008-08-27
2012-09-14
  • testom

    testom - 2008-08-27

    Hi, I have an problem;
    the language I use has an C#stylish syntax.But for correct out put I have to modify some lines of
    CSarp.pm; I have tryed to save this as foo.pm and got error.
    in language.txt
    Language: foo
    Extension: foo

    ERROR: Could not create NaturalDocs::Languages::foo object.

    Full Language Support: NaturalDocs::Languages::foo

    ># Class: NaturalDocs::Languages::foo
    ...
    >package NaturalDocs::Languages::foo;
    ...etc
    >>
    NaturalDocs:/home/testom/Desktop/docs/Config/Languages.txt:294: could not create NaturalDocs::Languages::foo object

    Natural Docs encountered the following error and was stopped:

    There is an error in /home/testom/Desktop/docs/Config/Languages.txt
    ...

    Do I have to change all the subs?? or where is the error?

    Many thanks testom

     
    • XL64

      XL64 - 2008-08-27

      Too add C.pm file This is what i did :

      • Copy CSharp.pm to C.pm and modify it

      • Add "use NaturalDocs::Languages::C;" to file Language.pm in $NATURAL_DOCS_DIR/Modules/NaturalDocs"

      • Add "Language: C/C++

      Extensions: c cpp h hpp cxx hxx
      Ignore Prefix in Index: @
      Ignore Function Prefix in Index: ~
      Full Language Support: NaturalDocs::Languages::C"
      to file Languages.txt in $NATURAL_DOCS_DIR/Config

      I think that's all I did and it worked

      XL.

       
    • testom

      testom - 2008-08-27

      GREAT THANKS,
      It work now perfect.
      I forgot the Language.pm !!

      Thanks a lot.

      testom

       

Log in to post a comment.