Thread overview
Anybody familiar with the VSIP SDK?
Nov 24, 2005
Lionello Lunesu
Nov 24, 2005
Lionello Lunesu
Nov 25, 2005
Hasan Aljudy
Nov 25, 2005
Lionello Lunesu
Nov 25, 2005
rsl
Nov 25, 2005
Lionello Lunesu
November 24, 2005
Hi,
I'm downloading the Visual Studio 2005 Integration SDK, and plan to make an
add-in for DMD, at least for compiling, but perhaps later also for syntax
check/coloring.

Is anybody familiar with this writing this kind-of VS add-in? There should be samples included with the SDK, but any tips are welcomed.

L.


November 24, 2005
HELP!
I need "the appropriate lexical (lex) and grammar (yacc) files". Who can
help me?

But do notice the reference below to Flex, Bison, Cygwin ; )

L.

------
The Visual Studio Language Service Wizard can quickly establish a Babel language service for a new Visual Studio language. For more information on Babel, see Babel Package Overview. You can provide language service support for your own language by specifying the appropriate lexical (lex) and grammar (yacc) files, or for a sample language, My C Package, provided with the Visual Studio Industry Partner (VSIP) program. The Language Service Wizard allows you to define syntax highlighting, syntax checking, block commenting, brace matching, statement completion, and quick info for your language.

Note
The lexer and parser tools are not shipped with the Visual Studio SDK. There
are a number of sources for lexers and parsers; two commonly used programs
are lex and yacc. Alternatively, you can use open source versions of lex and
yacc called flex and bison (one source for the latter two is Cygwin
[http://www.cygwin.com]). Whichever tools you use, be sure to check the
license agreement for those tools before distributing your language service.
The Language Service Wizard requires a lexer tool and a parser tool to be
installed before the language service as created through the wizard can be
built.


November 24, 2005
Dave Sieber developed (with VSIP) a lexer/parser for Visual Studio using the Babel SDK.  Unfortunately, a full parser cannot (without missing correct syntax) be done, since D's grammar is not LALR(1).

The correct way would be to hook into the regular Visual Studio interfaces, and not use flex/bison.  Unfortunately, this is more involved.

-[Unknown]


> HELP!
> I need "the appropriate lexical (lex) and grammar (yacc) files". Who can help me?
> 
> But do notice the reference below to Flex, Bison, Cygwin ; )
> 
> L.
> 
> ------
> The Visual Studio Language Service Wizard can quickly establish a Babel language service for a new Visual Studio language. For more information on Babel, see Babel Package Overview. You can provide language service support for your own language by specifying the appropriate lexical (lex) and grammar (yacc) files, or for a sample language, My C Package, provided with the Visual Studio Industry Partner (VSIP) program. The Language Service Wizard allows you to define syntax highlighting, syntax checking, block commenting, brace matching, statement completion, and quick info for your language.
> 
> Note
> The lexer and parser tools are not shipped with the Visual Studio SDK. There are a number of sources for lexers and parsers; two commonly used programs are lex and yacc. Alternatively, you can use open source versions of lex and yacc called flex and bison (one source for the latter two is Cygwin [http://www.cygwin.com]). Whichever tools you use, be sure to check the license agreement for those tools before distributing your language service.
> The Language Service Wizard requires a lexer tool and a parser tool to be installed before the language service as created through the wizard can be built. 
> 
> 
November 25, 2005
I also suspect that you can't color "nested comments" correctly, because it cannot be defined as a regular expression, and as far as I understand, the "lex" tools works on the assumption that all "tokens" are defined as regular expressions.
I maybe wrong, of course.

Unknown W. Brackets wrote:
> Dave Sieber developed (with VSIP) a lexer/parser for Visual Studio using the Babel SDK.  Unfortunately, a full parser cannot (without missing correct syntax) be done, since D's grammar is not LALR(1).
> 
> The correct way would be to hook into the regular Visual Studio interfaces, and not use flex/bison.  Unfortunately, this is more involved.
> 
> -[Unknown]
> 
> 
>> HELP!
>> I need "the appropriate lexical (lex) and grammar (yacc) files". Who can help me?
>>
>> But do notice the reference below to Flex, Bison, Cygwin ; )
>>
>> L.
>>
>> ------
>> The Visual Studio Language Service Wizard can quickly establish a Babel language service for a new Visual Studio language. For more information on Babel, see Babel Package Overview. You can provide language service support for your own language by specifying the appropriate lexical (lex) and grammar (yacc) files, or for a sample language, My C Package, provided with the Visual Studio Industry Partner (VSIP) program. The Language Service Wizard allows you to define syntax highlighting, syntax checking, block commenting, brace matching, statement completion, and quick info for your language.
>>
>> Note
>> The lexer and parser tools are not shipped with the Visual Studio SDK. There are a number of sources for lexers and parsers; two commonly used programs are lex and yacc. Alternatively, you can use open source versions of lex and yacc called flex and bison (one source for the latter two is Cygwin [http://www.cygwin.com]). Whichever tools you use, be sure to check the license agreement for those tools before distributing your language service.
>> The Language Service Wizard requires a lexer tool and a parser tool to be installed before the language service as created through the wizard can be built.
>>
November 25, 2005
"Unknown W. Brackets" <unknown@simplemachines.org> wrote in message news:dm59de$16tv$1@digitaldaemon.com...
> Dave Sieber developed (with VSIP) a lexer/parser for Visual Studio using the Babel SDK.  Unfortunately, a full parser cannot (without missing correct syntax) be done, since D's grammar is not LALR(1).

Thanks! I found some stuff on
http://reverie.xrea.jp/wiki/VSpluginD.html
Seems he's way ahead of me : )
Not sure if that's Dave Sieber though.

> The correct way would be to hook into the regular Visual Studio interfaces, and not use flex/bison.  Unfortunately, this is more involved.

I'm very reluctant to enter that domain...

L.


November 25, 2005
>Not sure if that's Dave Sieber though.
He is developer of DCoder http://www.dsource.org/projects/dcoder/ and I'm working on VSpluginD. developed in C# and MPF.

There are samples in VS SDK
-Archive\Babel\MyCLangService\    //Language Service
-Archive\MyCPkgs\    //Project Service
Using these as template are good starting points.
There are other Babel samples, ECMA Script,Pascal,Scheme.

Although I think Babel SDK interface is complecated and difficult to understand. and writing complete DGrammer with flex/bison is not easy task.

If don't use flex/bison and Babel SDK.
Lualite http://www.sjbrown.co.uk/?code=lualite
source code is useful for reference.
D Syntax Highlighting and Keyword Completion is easily done
by small modification of Lualite source code .


In article <dm6mnq$311v$1@digitaldaemon.com>, Lionello Lunesu says...
>
>
>"Unknown W. Brackets" <unknown@simplemachines.org> wrote in message news:dm59de$16tv$1@digitaldaemon.com...
>> Dave Sieber developed (with VSIP) a lexer/parser for Visual Studio using the Babel SDK.  Unfortunately, a full parser cannot (without missing correct syntax) be done, since D's grammar is not LALR(1).
>
>Thanks! I found some stuff on
>http://reverie.xrea.jp/wiki/VSpluginD.html
>Seems he's way ahead of me : )
>Not sure if that's Dave Sieber though.
>
>> The correct way would be to hook into the regular Visual Studio interfaces, and not use flex/bison.  Unfortunately, this is more involved.
>
>I'm very reluctant to enter that domain...
>
>L.
>
>


November 25, 2005
"rsl" <rsl_member@pathlink.com> wrote in message news:dm6tjr$7b1$1@digitaldaemon.com...
> >Not sure if that's Dave Sieber though.
> He is developer of DCoder http://www.dsource.org/projects/dcoder/ and I'm working on VSpluginD. developed in C# and MPF.

Thanks for that plug-in! I've got it working in VS2005 Professional; only the folders are different from Express.

L.


November 26, 2005
I'm afraid you are.  You can have code and state, so you can easily highlight nested comments.

The highlighter Dave Sieber wrote works wonderfully; it's the syntax checking that is the problem.

-[Unknown]


> I also suspect that you can't color "nested comments" correctly, because it cannot be defined as a regular expression, and as far as I understand, the "lex" tools works on the assumption that all "tokens" are defined as regular expressions.
> I maybe wrong, of course.
November 26, 2005
That's not.  Dave Sieber posted on this newsgroup before, but I don't know if/where he has a website.  I know there's some stuff on dsource.org.

From that page:
Currently Syntax Coloring is privided by C++ Language Service.

So, it's not going to work 100%, and it won't support nested comments.

-[Unknown]


> "Unknown W. Brackets" <unknown@simplemachines.org> wrote in message news:dm59de$16tv$1@digitaldaemon.com...
> 
>>Dave Sieber developed (with VSIP) a lexer/parser for Visual Studio using the Babel SDK.  Unfortunately, a full parser cannot (without missing correct syntax) be done, since D's grammar is not LALR(1).
> 
> 
> Thanks! I found some stuff on
> http://reverie.xrea.jp/wiki/VSpluginD.html
> Seems he's way ahead of me : )
> Not sure if that's Dave Sieber though.
> 
> 
>>The correct way would be to hook into the regular Visual Studio interfaces, and not use flex/bison.  Unfortunately, this is more involved.
> 
> 
> I'm very reluctant to enter that domain...
> 
> L.
> 
>