473,326 Members | 2,076 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

C# Preprocessor

Hello,

I'm looking for a C# Preprocessor (shareware with source, if possible)
which has the functionality of preprocessors which already exist in
other languages, e.g.

http://www.zeitungsjunge.de/delphi/dipp/

DIPP is a Pascal Preprocessor. The purpose of DIPP is to manipulate
Pascal source code files.

DIPP can

* remove comments
* process compiler directives and switches
* remove compiler conditionals by wild card masks
* remove compiler directives by wild card masks
* insert, read, or skip include files by wild card masks
* extract units' interface sections

Such a tool would be very useful for parsing C# source files before
making them available to third parties. Can anybody suggest such a tool
to me please?

--
Christopher Ireland
Posted with XanaNews version 1.17.6.6

"... the question of whether Machines Can Think ... is about as
relevant
as the question of whether Submarines Can Swim."
Edsger Wybe Dijkstra
Dec 23 '05 #1
2 2779
Christopher Ireland wrote:
Hello,

I'm looking for a C# Preprocessor (shareware with source, if possible)
which has the functionality of preprocessors which already exist in
other languages, e.g.

http://www.zeitungsjunge.de/delphi/dipp/

DIPP is a Pascal Preprocessor. The purpose of DIPP is to manipulate
Pascal source code files.

DIPP can

* remove comments
* process compiler directives and switches
* remove compiler conditionals by wild card masks
* remove compiler directives by wild card masks
* insert, read, or skip include files by wild card masks
* extract units' interface sections

Such a tool would be very useful for parsing C# source files before
making them available to third parties. Can anybody suggest such a
tool to me please?


I'm not aware of such a preprocessor for C# as the usage for such a
tool isn't that common. I've written a comment stripper once, see this
blogpost:
http://weblogs.asp.net/fbouma/archiv...19/423047.aspx

It's not 100% perfect, but as the source comes with it, you can tweak
it further. It's easily upgradable for doing other things as well, just
add more regexp's :)

FB

--
------------------------------------------------------------------------
Get LLBLGen Pro, productive O/R mapping for .NET: http://www.llblgen.com
My .NET blog: http://weblogs.asp.net/fbouma
Microsoft MVP (C#)
------------------------------------------------------------------------
Dec 24 '05 #2
Frans Bouma [C# MVP] wrote:
Christopher Ireland wrote:
Such a tool would be very useful for parsing C# source files before
making them available to third parties. Can anybody suggest such a
tool to me please?


I'm not aware of such a preprocessor for C# as the usage for such a
tool isn't that common. I've written a comment stripper once, see this
blogpost:
http://weblogs.asp.net/fbouma/archiv...19/423047.aspx

It's not 100% perfect, but as the source comes with it, you can tweak
it further. It's easily upgradable for doing other things as well,
just add more regexp's :)

FB


Thanks Frans!

--
Christopher Ireland
Posted with XanaNews version 1.17.6.6

"... the question of whether Machines Can Think ... is about as
relevant
as the question of whether Submarines Can Swim."
Edsger Wybe Dijkstra
Dec 24 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

205
by: Jeremy Siek | last post by:
CALL FOR PAPERS/PARTICIPATION C++, Boost, and the Future of C++ Libraries Workshop at OOPSLA October 24-28, 2004 Vancouver, British Columbia, Canada http://tinyurl.com/4n5pf Submissions
24
by: Nudge | last post by:
I have an array, and an unrolled loop which looks like this: do_something(A); do_something(A); .... do_something(A); I thought: why should I type so much? I should write a macro. So I was...
16
by: Trying_Harder | last post by:
Is it possible to redefine a macro with global scope after undefining it in a function? If yes, could someone explain how? /If/ my question above isn't very clear you can refer to the...
13
by: seemanta dutta | last post by:
Greetings C gurus, I have used preprocessor directives since a very long time. But whenever I see some professional piece of C code, the linux kernel for example, I get literally confused by the...
18
by: /* frank */ | last post by:
My teacher said that array in C is managed by preprocessor. Preprocesser replace all array occurences (i.e. int a ) with something that I don't understand/remember well. What's exactly happens...
13
by: Chris Croughton | last post by:
Is the following code standard-compliant, and if so what should it do? And where in the standard defines the behaviour? #include <stdio.h> #define DEF defined XXX int main(void) { int...
9
by: Walter Roberson | last post by:
I have run into a peculiarity with SGI's C compiler (7.3.1.2m). I have been reading carefully over the ANSI X3.159-1989 specification, but I cannot seem to find a justification for the behaviour....
2
by: Paolo | last post by:
I imported a VC++6.0 project into VC++7.1. The conversion operation makes a mess with Preprocessor Definitions, adding a "$(NoInherit)" for each file. For example: I had a DLL project in VC++6.0...
32
by: spibou | last post by:
Is the output of the C preprocessor deterministic ? What I mean by that is , given 2 compilers which conform to the same standard, will their preprocessors produce identical output given as input...
31
by: Sam of California | last post by:
Is it accurate to say that "the preprocessor is just a pass in the parsing of the source file"? I responded to that comment by saying that the preprocessor is not just a pass. It processes...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.