Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Is there any OS not written in C?

Name: Anonymous 2009-03-21 6:29

Name: Anonymous 2009-03-21 23:15

MS-DOS, FreeDOS (Asm)

Name: Anonymous 2009-03-21 23:28

>>37,39
Back to /b/ and/or /g/, please.

Name: Anonymous 2009-03-21 23:37

>>42
No tripcode, so it's probably /b/.

Name: Anonymous 2009-03-21 23:39

>>41
;/*
; *                      Microsoft Confidential
; *                      Copyright (C) Microsoft Corporation 1991
; *                      All Rights Reserved.
; */
/* convert an arbitrary based number to an integer */

#include <ctype.h>
#include "tools.h"

/* p points to characters, return -1 if no good characters found
 * and base is 2 <= base <= 16
 */
int ntoi (p, base)
char *p;
int base;
{
    register int i, c;
    flagType fFound;

    if (base < 2 || base > 16)
        return -1;
    i = 0;
    fFound = FALSE;
    while (c = *p++) {
        c = tolower (c);
        if (!isxdigit (c))
            break;
        if (c <= '9')
            c -= '0';
        else
            c -= 'a'-10;
        if (c >= base)
            break;
        i = i * base + c;
        fFound = TRUE;
        }
    if (fFound)
        return i;
    else
        return -1;
}

Name: Anonymous 2009-03-21 23:45

>>44
They have BBCODE on computers now.

Name: Anonymous 2009-03-21 23:51

>>45
>>44 used BBCODE. get a better browser.

Name: Anonymous 2009-03-22 0:02

>>44
Jesus Christ! Use [code][/code] tags! They're there for a reason.

IHBT

Name: Anonymous 2009-03-22 0:23

>>40
Poor taste? That would be any place where people defend Apple products.

Name: Anonymous 2009-03-22 0:27

Please don't feed the trolls

Name: Anonymous 2009-03-22 0:33

>>48
Apple's GUI has its flaws, but I prefer it over CDE, OpenWindows, or whatever the hell it is they include with Solaris these days.

Name: Anonymous 2009-03-22 0:39

whatever the hell it is they include with Solaris these days.
gnome.

>>47
look again.
there is a code tag there:
;/*
; *                      Microsoft Confidential
; *                      Copyright (C) Microsoft Corporation 1991
; *                      All Rights Reserved.
; */
/* convert an arbitrary based number to an integer */

#include <ctype.h>
#include "tools.h"

/* p points to characters, return -1 if no good characters found
 * and base is 2 <= base <= 16
 */
int ntoi (p, base)
char *p;
int base;
{
    register int i, c;
    flagType fFound;

    if (base < 2 || base > 16)
        return -1;
    i = 0;
    fFound = FALSE;
    while (c = *p++) {
        c = tolower (c);
        if (!isxdigit (c))
            break;
        if (c <= '9')
            c -= '0';
        else
            c -= 'a'-10;
        if (c >= base)
            break;
        i = i * base + c;
        fFound = TRUE;
        }
    if (fFound)
        return i;
    else
        return -1;
}

Name: Anonymous 2009-03-22 0:46

>>51
Needs more codes tags. IHBTA

Name: Anonymous 2009-03-22 0:46

>>52
*code

Name: Anonymous 2009-03-22 2:33

>>44
What has been seen cannot be unseen.
The viral nature of proprietary software has infected me.

Name: Anonymous 2009-03-22 3:20

Haiku is written in C++.

Name: Anonymous 2009-03-22 4:01

>>54
at least you're not required to distribute it now like you would be if it were that viral GNU diarrhea.

Name: Anonymous 2009-03-22 5:17

>>54
Never forget the concepts of fair use, trivial samples (a trivial hello world program, a trivial section of a larger work) and the fact that copyright only covers the specific implementation of an expression and not the expression itself.

Name: Anonymous 2009-03-22 11:09

>>57
The power of the imaginary property compels you.

Name: Anonymous 2009-03-22 12:04

Anything worth mentioning is written in C.

Which kinda blows because I have to deal with primitive C retardation when doing my operating systems course projects.

Name: Anonymous 2009-03-22 13:32

you cant write an OS in anything other than C because you need to bootstrap the system somehow

Name: Anonymous 2009-03-22 13:41

if you think C is primitive then drop out of school because you wont be able to take it in the real world

Name: Anonymous 2009-03-22 13:42

>>60
IHBT, but how does that limit the language used?

Name: Anonymous 2009-03-22 13:51

>>61
If you think C isn't primitive, you belong in the 1950s.

Name: Anonymous 2009-03-22 14:22

>>63
it isnt primitive, it gives the programmer all the tools he needs to do anything he wants. if you cant handle that, then youre a primitive programmar and should stick with ruby programmering on your rails

Name: Anonymous 2009-03-22 14:22

>>63
Protip: There was no C in the 1950s.

Name: Anonymous 2009-03-22 14:23

>>63
Protip: There was no C in the 1950s.

Name: Anonymous 2009-03-22 14:59

>>66
So they did not think C was primitive. >>63 is right, you know that?

Name: Anonymous 2009-03-22 16:46

>>64
It's primitive and doesn't even have usable macros.

>>65,66
No shit. The point is that C lacks basic features that predate it by decades.

Name: Anonymous 2009-03-22 16:53

>>68
I've been programming C since the early 80s and can safely say the macros work fine. Perhaps you should stick to programming toy programs in FIOC.

Name: Anonymous 2009-03-22 17:08

>>68
The point is that C lacks basic features that predate it by decades.
C was designed to be a minimalist language that was easily portable. Complain all you want that it lacks features, but it takes a long time for any feature to gain widespread adoption(see Garbage Collection) and why bother including non-mainstream features in a language that is designed to be as small as possible.

Name: Anonymous 2009-03-22 17:24

(see Garbage Collection)
See LISP

Name: Anonymous 2009-03-22 17:39

>>70
C could have at least included keyword arguments and useful macros (no, >>69, the macros do not work fine: there's no way to put logic in your code generation).

Name: Anonymous 2009-03-22 17:55

>>44
what.
why would they not just do this instead?
int ntoi(char *p, int base)
{ register int i = 0, fFound = 0;
  if(1 < base && base < 37)
    for(register int c;
        fFound |= (isdigit(c = tolower(*p++)) &&
                   (c -= c <= '9' ? '0' : 'a' - 10) < base);
        i = i * base + c);
  return fFound ? i : -1; }

Name: Anonymous 2009-03-22 17:58

((no, >>69, the macros do not work fine: there's no way to put logic in your code generation)
if you use gcc, there is.

Name: Anonymous 2009-03-22 18:32

>>74
If I used gcc, I would have two problems.

But explain yourself anyway.

Name: Anonymous 2009-03-22 19:11

>>75
#ifdef

Name: Anonymous 2009-03-22 19:30

>>76
I'm talking about proper meta-programming logic, not your mickey mouse conditional ifs.

Name: Anonymous 2009-03-22 19:33

>meta
Back to /b/, please

Name: Anonymous 2009-03-22 19:35

>>78

You don't know what meta means in this context, get the fuck off /prog/

Name: Anonymous 2009-03-22 19:40

>>76
Oh, wow. That's what you think code generation is?

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List