<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type"/>
</head>
<body>
<p style="margin: 0;">
<span>
<span></span>
</span>
</p>
<p style="margin: 0px;"></p>
<div style="margin: 5px 0px 5px 0px;">
<br/>
Andrew Pennebaker <andrew.pennebaker@gmail.com> hat am 16. Oktober 2011 um 19:53 geschrieben:
<br/>
<br/>
<blockquote style="margin-left: 0px; padding-left: 10px; border-left: solid 1px blue;" type="cite">There are plenty who do believe it's convenient to hide compilation in the background--the users of instantfpc. Syntax for shebangs in fpc would bridge instantfpc and traditional Pascal code. You would no longer have to treat instantfpc code as a special case, because fpc wouldn't mind the shebangs.</blockquote>
</div>
<p style="margin: 0px;">The great feature of instantfpc is that it combines two steps: compiling and runnning. The other great feature is that it uses a cache directory, so that the source directory does not get polluted by ppu and executables and that it starts scripts faster than php, bash etc. This way you get the speed of a compiled program combined with the ease of use of a script.</p>
<p style="margin: 0px;">If you add the ability to fpc to ignore the shebang line, you are still missing the important features of instantfpc.</p>
<p style="margin: 0px;">In other words: As long as you don't add the other abilities to fpc too, you still need instantfpc.</p>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;"> </p>
<div style="margin: 5px 0px 5px 0px;">
<blockquote style="margin-left: 0px; padding-left: 10px; border-left: solid 1px blue;" type="cite">
<div></div>
<div>It's the same for case statements and if statements. If you really prefer if statements for everything, you can write everything with if statements. But for those who recognize the convenience of case statements, it's nice to have case statements.</div>
<div></div>
<div>Adding shebangs would not change the nature of Pascal. It's first and foremost a compiled, highly optimized language. Shebangs would allow Pascal to better fill the Unix scripting niche.</div>
</blockquote>
</div>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;">Normally a shebang script does not create files - it can run in a readonly directory.</p>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;"> </p>
<div style="margin: 5px 0px 5px 0px;">
<blockquote style="margin-left: 0px; padding-left: 10px; border-left: solid 1px blue;" type="cite">
<div>
<div></div>
<div>[...]</div>
<div>$ fpc hello.pas</div>
<div>
<div>hello.pas(1,1) Error: Illegal char constant</div>
<div>hello.pas(1,2) Fatal: Syntax error, "BEGIN" expected but "const string" found</div>
</div>
</div>
</blockquote>
</div>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;">To compile use:</p>
<p style="margin: 0px;">instantfpc --skip-run -B hello.pas</p>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;">If you don't like typing so much, define an alias for your shell.</p>
<p style="margin: 0px;">alias ifp='instantfpc --skip-run -B' </p>
<p style="margin: 0px;"> </p>
<p style="margin: 0px;">Mattias</p>
<p style="margin: 0px;"> </p>
</body>
</html>