- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I want to check if there is some parameter has already been defined,so I worked like this :
#ifdef NO64BITS
INTEGER, PARAMETER, public :: i8b = i4b
#else
INTEGER, PARAMETER, public :: i8b = SELECTED_INT_KIND(16)
#endif
But when I compile it ,the compliler shows :"warning, bad # preprocessor line" .I'm a newer to fortran,so I don't know what and how to do with it.Any answer is appreciated!
Have a nice day!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It still act wrong as before after I done as your suggestion.........
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It still act wrong as before after I done as your suggestion.........
Make sure that the "#" symbol is in the first column, and that you are indeed invoking the preprocessor (with the /fpp command-line option)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have changed the 'preprocess source file ' --> (Yes/fpp),but it shows the same error.What I use is visual studio 2008+ intel fortran 11.1.051; I think it may be act as mkl_fftw_ms, so I try to connect with mkl_solver.lib mkl_intel_c.lib mkl_intel_thread.lib mkl_core.lib,but it doesn't worktoo.....I have no idea to do anything with it now ,help me!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sorry,it's my fault..... according to my command ,I has lost a flag 'Q' --/fpp not work ,/Qfpp work well !! But I found another intresting phenomena. In visual studio 2008+intel fortran 11.051,I want to change the preprocess like this : properties--> Fortran-->preprocessor-->preprocess source file,only /fpp options canbe chosen,and if you want to add /Qfpp,then command Line can do this!
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Runs the Fortran preprocessor on source files before compilation.
IDE Equivalent
Windows: Preprocessor > Preprocess Source File
Linux: None
Mac OS X: Preprocessor > Preprocess Source File
Architectures
IA-32, Intel 64, IA-64 architectures
Syntax
|
Linux and Mac OS X: |
fpp fpp[="option"] -nofpp |
|
Windows: |
/fpp /fpp[:"option"] /nofpp /Qfpp /Qfpp[:"option"] |
Arguments
|
n |
Deprecated. Tells the compiler whether to run the preprocessor or not. Possible values are:
|
||||
|
option |
Is a Fortran preprocessor (fpp) option; for example, "-macro=no", which disables macro expansion. The quotes are required. For a list of fpp options, see Fortran Preprocessor Options. |
Default
|
nofpp |
The Fortran preprocessor is not run on files before compilation. |
Description
This option runs the Fortran preprocessor on source files before they are compiled.
If the option is specified with no argument, the compiler runs the preprocessor.
If 0 is specified for n, it is equivalent to nofpp.Note that argument n is deprecated.
We recommend you use option Qoption,fpp,"option" to pass fpp options to the Fortran preprocessor.
Alternate Options
Linux and Mac OS X: -cpp
Windows: /Qcpp
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sorry,it's my fault..... according to my command ,I has lost a flag 'Q' --/fpp not work ,/Qfpp work well !! But I found another intresting phenomena. In visual studio 2008+intel fortran 11.051,I want to change the preprocess like this : properties--> Fortran-->preprocessor-->preprocess source file,only /fpp options canbe chosen,and if you want to add /Qfpp,then command Line can do this!
Thanks!
I'm glad you're working, but I'm puzzled by what you've said here.
/fpp is equivalent to /Qfpp, and in fact we will be deprecating (slowly getting rid of) /Qfpp in a future release.
The documentation does list optional numbers after the "fpp" part, but those are ignored (and were there for compatibility with the V7.1 Fortran compiler).
Anyway, would you mind posting the build log from your case that was failing simply by setting Fortran-->preprocessor-->preprocess source file ? I'm curious about it .
thanks --
- Lorri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm glad you're working, but I'm puzzled by what you've said here.
/fpp is equivalent to /Qfpp, and in fact we will be deprecating (slowly getting rid of) /Qfpp in a future release.
The documentation does list optional numbers after the "fpp" part, but those are ignored (and were there for compatibility with the V7.1 Fortran compiler).
Anyway, would you mind posting the build log from your case that was failing simply by setting Fortran-->preprocessor-->preprocess source file ? I'm curious about it .
thanks --
- Lorri
Compiling with Intel Visual Fortran 11.1.051 [IA-32]...
ifort /nologo /debug:full /Od /Qfpp /gen-interfaces /warn:interfaces /module:"Debug" /object:"Debug" /traceback /check:bounds /libs:static /threads /dbglibs /c /extfpp:cfortran.h,cfitsio.h /fpp /libs:dll cfitsio.lib /MD /iface:cvf /Qvc9 /Qlocation,link,"C:Program Files (x86)Microsoft Visual Studio 9.0VCbin" "E:lib_newHealpix_2.13asrcf90modhealpix_types.F90"
E:lib_newHealpix_2.13asrcf90modhealpix_types.F90(45): #error: '#ifdef' argument starts with wrong symbol.
Console1 : error PRJ0019: A tool returned an error code
and the original code is:
#ifdef (NO64BITS)
INTEGER, PARAMETER, public :: i8b = i4b
#else
INTEGER, PARAMETER, public :: i8b = SELECTED_INT_KIND(16)
#endif
Thanks for your attention!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Remove the parentheses around the #ifdef argument, ie:
#ifdef NO64BITS
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page