Page 1 of 2
Source code
Posted: Fri Oct 08, 2004 11:42 am
by kataklinger
Including other configuration files like makefiles, ...
Re:Source code
Posted: Sat Oct 09, 2004 8:23 am
by crc
The actual sourcecode for the minimal build of my OS is 1,237 lines; the extra drivers add another 60 lines, and the editor is about 15 lines. The makefile is 20 lines. And 65 lines for the optional serial console. So it's a total of 1,397 lines at the moment. It could be shrunk to under 1,000 lines if I squeezed out blank lines and comments.
I expect it to grow to 2,500-3,000 lines once I've implemented everything I want.
Re:Source code
Posted: Sat Oct 09, 2004 9:49 am
by distantvoices
Hm .... currently, my task control block management code alone contains ca 1200 lines of code.
the amount of lines is gonna raising as development continues.
Re:Source code
Posted: Mon Oct 11, 2004 2:37 am
by Solar
Hmm... for all that I have worked on Pro-POS' design for over two years, and spent quite some time in working on the PDCLib, my "accountable" lines amount to a measly 5000 or so, including gratuitious commenting.
With regards to the PDCLib, that will change as soon as my tower recovers from a long-standing illness (called Windows). Working on a 640x240 PDA with 1/2 keyboard and no compiler hampers coding productivity a bit.
Re:Source code
Posted: Mon Oct 11, 2004 3:24 am
by Pype.Clicker
51602 lines in "*.c","*.h"
2461 lines of makefiles (including copy/pasted makefiles, templates and commands for DOS/linux/cygwin configurations)
1032 lines of
CodeMonkey plugins and
IDL files
35090 lines of
tools
::)
Re:Source code
Posted: Mon Oct 11, 2004 4:59 am
by Brendan
Hi,
Here's the line counts for the current rewrite of my OS (which is roughly 99.98% NASM and a few make files). These line counts don't include blank lines (generated via "cat -b *"):
2216 for include files
17657 for kernel
31119 for mixed boot/configuration code
21619 for regional database source files
748 for DOS utilities (written specifically for the OS)
184 source for generating boot images
73543 TOTAL source
Then there's 3340 lines of html documentation, plus the source code from the previous version of the OS which will be "ported" to the new version (GUI, CLI, PS/2 keyboard & mouse driver, user interface code, virtual filesystem code, floppy driver, serial port driver, etc)...
Cheers,
Brendan
Re:Source code
Posted: Mon Oct 11, 2004 7:25 am
by bubach
Lines in ASM is a bit shorter then lines in C.. Couldn?t we count the size of the source/binarys instead?
Re:Source code
Posted: Mon Oct 11, 2004 7:27 am
by Solar
10 lines of working ASM bring as much fame as 10 lines of working C. ;D
Re:Source code
Posted: Mon Oct 11, 2004 10:23 am
by Candy
Solar wrote:
10 lines of working ASM bring as much fame as 10 lines of working C. ;D
Actually, the question as it is now asks for the number of line numbers. I haven't used line numbers since GWBasic, which was a long long time ago. My OS code thus doesn't have line numbers
Re:Source code
Posted: Mon Oct 11, 2004 1:42 pm
by Dreamsmith
How many line numbers does your source code have?
HA! I didn't even notice that. I'm afraid I have to change my answer to zero -- I haven't used line numbers since my days of coding in Applesoft BASIC.
Good eye, Candy. The rest of us were asleep at the keyboard...
Re:Source code
Posted: Mon Oct 11, 2004 1:52 pm
by bubach
number of line numbers
and there you lost me... ???
Re:Source code
Posted: Mon Oct 11, 2004 2:03 pm
by Dreamsmith
bubach wrote:
number of line numbers
and there you lost me... ???
If the question is "How many line numbers...?", the answer should be the number of line numbers. Consider:
Code: Select all
5 REM Simple Eliza
10 PRINT "How are you?"
20 INPUT A$: PRINT
30 PRINT "Why do you feel " + A$ + "?"
40 INPUT A$
: PRINT
50 GOTO 30
The above code has 7 lines, but only 6 line numbers (5, 10, 20, 30, 40, & 50).
Re:Source code
Posted: Mon Oct 11, 2004 2:16 pm
by bubach
are u sure that is what he?s asking? sound wierd..
anyway, my current version of Notepad don?t support line numbering..
a guess should be a couple of thusands, i don?t think i am over 10.000 yet..
/ Christoffer
Re:Source code
Posted: Mon Oct 11, 2004 3:14 pm
by Dreamsmith
bubach wrote:are u sure that is what he?s asking? sound wierd..
I don't think it's what he
meant to ask, but it is what he
did ask.
bubach wrote:anyway, my current version of Notepad don?t support line numbering..
Actually, it does. You just type the line number at the start of the line. Note that the "line number" has nothing to do with which line of the source code it is. Consider:
Code: Select all
12 REM Another example
39 PRINT "Hello, world."
81 PRINT "How are you doing?"
117 INPUT A$
118 PRINT "That's nice."
2842 END
No editor support is required, indeed, how would the editor have any idea what the line number of a line is, if you didn't enter it in? The "line number" has nothing to do with the line's position in a file. Think of it as a numeric label, although it's a bit more than that -- it also determined execution order.
For real fun, have your line numbers out of order! (They'll execute in numeric order, least to greatest, but there's no requirement that they be ordered that way in a source text file -- lines can be entered in any order.) Enter and execute this into a BASIC interpretter:
Code: Select all
20 PRINT "A"
40 PRINT "B"
10 PRINT "C"
30 END
The output of this program will be:
BASIC -- gotta love it...
Re:Source code
Posted: Tue Oct 12, 2004 12:22 am
by bubach
yeah, yeah... u know what i meant didn?t you?
(PS: i know old basic, i am not _that_ young
)