- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
print *, "123 456"results in
123
456
but i want
123 456
how can easily get this, is there a compiler option?
of course i could use
print *, "123", "n456"
but i don't like this.
Link Copied
9 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Isn't that an ugly feature?! -vms will get you what you want. In 8.0, this
recognition will be off by default and there will be a new switch to turn it on if you want it.
Steve
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
thanks! (but:)
ugly?: yes. and funny:
compiling gives (an error message twice as long as the program):
i didn't want to use it as an escape character! ;-)
!!! unfortunately this message remains when compiling with -vms !!! ???
i use:
ugly?: yes. and funny:
program backslash print *, "" end program
compiling gives (an error message twice as long as the program):
program BACKSLASH print *, "" ^ Warning 18 at (2:backslash.f90) : used as an escape character is an extension to standard Fortran 95 ^ Error 5 at (2:backslash.f90) : incomplete string 1 Error compilation aborted for backslash.f90 (code 1)
i didn't want to use it as an escape character! ;-)
!!! unfortunately this message remains when compiling with -vms !!! ???
i use:
Intel Fortran Compiler for 32-bit applications, Version 7.1 Build 20030701Z Copyright (C) 1985-2003 Intel Corporation. All rights reserved. FOR NON-COMMERCIAL USE ONLY GNU ld version 2.13.90.0.2 20020802 Supported emulations: elf_i386 i386linux elf_i386_glibc21
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ifc -nbs sandwich.f90
program BACKSLASH
3 Lines Compiled
tim@linux:/windows/E/src/net> ./a.out
Intel Fortran Compiler for 32-bit applications, Version 7.1 Build 20030412Z
FOR NON-COMMERCIAL USE ONLY
GNU ld version 2.13.90.0.2 20020802
Supported emulations:
elf_i386
i386linux
elf_i386_glibc21
program BACKSLASH
3 Lines Compiled
tim@linux:/windows/E/src/net> ./a.out
Intel Fortran Compiler for 32-bit applications, Version 7.1 Build 20030412Z
FOR NON-COMMERCIAL USE ONLY
GNU ld version 2.13.90.0.2 20020802
Supported emulations:
elf_i386
i386linux
elf_i386_glibc21
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
correction (sorry, cut and paste problem):
GNU ld version 2.11.90.0.29 (with BFD 2.11.90.0.29)
GNU ld version 2.11.90.0.29 (with BFD 2.11.90.0.29)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
As Tim suggests, add -nbs. This too won't be needed in 8.0. (Grumble - I hate it when Fortran implementors think they're writing a C compiler instead...)
Steve
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yes, now it works.
thank you both.
yes, i also like C, but i would appreciate that people are able to distinguish.
greetings,
sandwich
thank you both.
yes, i also like C, but i would appreciate that people are able to distinguish.
greetings,
sandwich
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
i have to correct:
as seen in the example below i could not use
as seen in the example below i could not use
print *, "123".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Why not? What happens? It seems to work for me with -vms and -nbs specified.
Steve
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
no, i meant without these options (my first message).
![](/skins/images/BC9A7A3465121B56B278007F4EE8899F/responsive_peak/images/icon_anonymous_message.png)
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page