For those of you who wish to use the C language at a slightly higher
level, please drop in to the following newsgroup:
comp.lang.xharbour
The xHarbour language is based on C and uses a variety of C
implementations to compile and link its applications. There are a several
GUI packages (free and commercial) to build your apps.
This language is based on the several xBase languages of ten years ago,
and has brought together the best features of all of them, and exposes
hundreds of C functions in a very easy C-like syntax:
Function main()
local cVrbl := "crackpot" // 'local' vrbl only accessible in
this function
private cAnotherVrbl := "nutcake" // 'private' vrbl avail
here and all functions below
CLS // Clears the terminal screen
? "I'm assessed mentally as : " + cVrbl // kicks up a line
and prints
? "I'm also known as a : " + cAnotherVrbl // kicks up anotyher
line and prints
/*
and of course, there are zillions of non-trivial features using
C and Databases where you can
become quickly productive and make a good living in our
language.
We have about 400 separate tests available for download to
demonstrate the *power* of
this language
*/
return nil
There are native built-in Comix databases available for your use, and a
variety of 'SQL' databases easily linkable to your apps.
You can also include C functions as part of your source code.
So, if you wish to quickly build an application based on C, then
xHarbour is the way to go.
To download the latest implementation of xHarbour:
- Visit www.whosaway.com
- Enter the Password: XHB
Better still, visit www.xharbour.com for support, documentation, and
help on Extended Harbour (xHarbour).
-Mel Smith
webmaster
www.whosaway.com
--
Mel Smith
OK, I get it: It's belated April Fools' joke. A NEW language, BASED on C!
Yeah, and I have a bridge to sell you. Nice try, but no cigar: you can
fool some of the people some of the time, and take advantage of nice
people often, but karma is a bitch!
great
> OK, I get it: It's belated April Fools' joke. A NEW language, BASED on C!
> Yeah, and I have a bridge to sell you. Nice try, but no cigar: you can
> fool some of the people some of the time, and take advantage of nice
> people often, but karma is a bitch!
>
Mike:
This is no joke !
1. You write your code in xHarbour (using all its features, classes,
functions, librairies).
2. You compile your source program(s) into C-based pcode.
3. You compile this 'C' code into object modules.
4. You link these object modules along with other provided librairies
into a high-speed executable.
xHarbour is relatively new (about ten years old), and has a few
thousand avid programmers making a good living building apps for businesses.
It is 'new' in the sense that the best features of the several xBase
languages (Clipper, dBase, xBase, FoxPro, etc) in existence then were
gathered together, and then those features were implemented into Harbour,
then xHarbour, and expanded over the past ten years. Altho xHarbour in its
bare form is a 'console-based' system, it has several GUI implementations --
some commercial, and a few good ones that are free and are vibrantly active.
I, myself, have built and installed installed several GUI apps and
several console apps at a major structural steel company which controls
their steel beam inventory, does their time-sheet accounting, and provided a
fast, automatic Estimating system for them to quote on major jobs.
These tasks all used xHarbour as the base language.
I am the webmaster of three web sites, and have an Apache Server beside
me in my office. I use an xHarbour app *solely* as the CGI for each of
these sites.
When (if) you visit my www.whosaway.com site, the password you input
(i.e., xhb) is received by my xharbour app (via Apache), databases are
searched, pages are built live and in real-time, and are sent back from
xHarbour to you via my Apache server. Who needs PHP when we have C and
xHarbour !
I'm definitely *not* one of the gurus that populate our ng
(comp.lang.xharbour), but those that visit there daily (including another
Smith -- David -- no relation) can answer any query you might have.
btw, xHarbour is Open Source, and the whole package can be downloaded
to your site via SVN -- or just go to my whosaway site and get the binary
package, and the source code to examine. You'll note that a good portion of
the functions are written in C itself, and the remainder in xHarbour.
You can, of course, build your own functions, and Classes if you wish.
There are a large variety of contributed librairies to handle a wide variety
of tasks: from scientific thru internet accessing code, thru business
processing thru massive database accessing.
-Mel Smith
Whatever it is it can't compare to C.
Bill
">
> Whatever it is it can't compare to C.
Bill:
The second step of the compilation produces C- Code, which is compiled
into object code, which is linked into an executable (i.e., an .exe)
So, it *is* C -- only a lot more productive and a lot less syntactical
nonsense.
If you want to 'bit-twiddle', you *still can* within xHarbour, or if you
want to be productive and 'sell your warss', its a lot faster and easier.
-Mel Smith
No, it's not C. The fact that it's compiled into a C-like language
doesn't make it C, nor does it make it topical here.
[...]
--
Keith Thompson (The_Other_Keith) ks...@mib.org <http://www.ghoti.net/~kst>
Nokia
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
It's quite common for start-up languages to compile to C for this
reason. However the source language itself doesn't have to be remotely
like C, it could be from the Lisp family of languages or something
entirely of your own invention.
>
> No, it's not C. The fact that it's compiled into a C-like language
> doesn't make it C, nor does it make it topical here.
>
Keith:
If I use Borland's C to compile each of my modules (say commonly,
several dozen major source .prg files) of my business application, and in
the logging sequence of the build there are no errors in that compilation,
then I *must* be using C ?
Or are you saying that Borland's C compiles all sorts of things that are
*not* C ??
See ??
But may you may wish to call it 'Hi C' for High-level C ??
-Mel Smith
You appear to be making the assertion that: Any generator of C is
topical here, not with regard to discussion of the generated C, but
with regard to the generator. Feels more like simple advocacy of a
not remotely close to C language. Are you saying that discussion of
xHarbour implementation that compiles without a C intermediate form
isn't relevant here, but one that compiles with one is? And do you
actually believe that is somehow sensible, or are you just trolling at
this point?
No, what I said is that it is compiled to C code, then compiled again by
your C-Compiler to object code
It's quite common for start-up languages to compile to C for this
reason. However the source language itself doesn't have to be remotely
like C, it could be from the Lisp family of languages or something
entirely of your own invention.
But xHarbour is absolutely like C !! Any C programmer, can sit right
down, and go to work ! (without worrying about being hand-cuffed with new,
restrictive syntactical rules)
(After about 11 years, you still call it a 'start-up' language ??? ---
Hmmmmph !)
**************************
aMyArray = ARRAY(12)
amyarray[1]="January" ; AMYARRAY[12] := "December"
AmYArRaY[6] := DATE()
(i.e., you don't get screwed with Upppercase, Lowercase syntax crap,
its all the same array)
or,
aCrap := {3.1415926,"3.14",date(),seconds(),"etcetera")
? aCrap[4] // kickls up a line, shows the seconds since midnite
For I = 1 to 1000000 // a simple loop and counter
// do anything here
Next
or
For i = 1000000 to 1 skip -2
// do anything backwards
next
while lHellFreezesOver // any logical/boolean vrbl or expression
// work away in here until time to exit
EXIT
end
-Mel
--
Joe Wright
"If you rob Peter to pay Paul you can depend on the support of Paul."
You appear to be making the assertion that: Any generator of C is
topical here, not with regard to discussion of the generated C, but
with regard to the generator. Feels more like simple advocacy of a
not remotely close to C language. Are you saying that discussion of
xHarbour implementation that compiles without a C intermediate form
isn't relevant here, but one that compiles with one is? And do you
actually believe that is somehow sensible, or are you just trolling at
this point?
David:
Yes, I'm just trolling for converts.
But your comment 'not remotely close' is absolutely false. Pronably,
xHarbour is the closest language to C there is without actually being C
itself. It was created by C experts who were trying (in the late 1990's) to
build a better higher-level language but based on the speed and power of C.
They did it: xHarbour !
... and it is being improved and made ever more powerful every day.
-Mel
Sadly I don't have a killfile.
-David
> **************************
>
> aMyArray = ARRAY(12)
>
> amyarray[1]="January" ; AMYARRAY[12] := "December"
> AmYArRaY[6] := DATE()
>
> (i.e., you don't get screwed with Upppercase, Lowercase syntax crap,
> its all the same array)
>
Removing case sensitivity from C is just a small syntactical change.
The arrays also seem to be 1-based - from experience, this is a grief.
But again, just a small change.
> or,
> aCrap := {3.1415926,"3.14",date(),seconds(),"etcetera")
>
> ? aCrap[4] // kickls up a line, shows the seconds since midnite
>
Not sure what's going on here. Type information seems to be carried
with the object. many languages do this, but not C, and it's quite a
big change. However is aCrap[4] calling seconds(), as you seem to
imply, or is it initialised with the earlier call (as most lanauges
would have it?)
>
>
> For I = 1 to 1000000 // a simple loop and counter
> // do anything here
> Next
>
> or
>
> For i = 1000000 to 1 skip -2
> // do anything backwards
> next
>
Standard for loops. Almost every language has them.
>
> while lHellFreezesOver // any logical/boolean vrbl or expression
> // work away in here until time to exit
> EXIT
> end
>
While loop and a break. Again, almost every language has this
construct. Or is the exit and exit from the program rather than the
loop? Again, we don't know.
There's not much point, in my view, making small cosmetic changes to C
syntax, like next and end as opposed to curly brackets, unless you
want to emphasise that the script is not C. The real difference seems
to be in the typing system. Carrying type information about at runtime
makes it easier to knock up small snippets of code. However in large
programs, there is a problem. Take x = squareroot(y). What happens if
y is negative? Do we get an imaginary? The problem is this tends to be
one of the things which is poorly documented. It's easy to lose track
of exactly what is being passed where.
"Sadly I don't have a killfile.
David:
Don't be concerned. I'll leave you folks alone from now on, and will
only watch, read, and try not to puke :(
-Mel
Which means, by definition, that your language is _not_ C. (If it _were_ C,
then why does it need to be "compiled to C code"?)
Perhaps, then, you would suggest that C++ (which was originally implemented
[IIRC] as a C++-to-C translator, which was then passed off to the C
compiler) is also C?
[...]
> But xHarbour is absolutely like C !! Any C programmer, can sit right
> down, and go to work ! (without worrying about being hand-cuffed with new,
> restrictive syntactical rules)
>
> (After about 11 years, you still call it a 'start-up' language ??? ---
> Hmmmmph !)
>
> **************************
>
> aMyArray = ARRAY(12)
Doesn't look like C to me.
> amyarray[1]="January" ; AMYARRAY[12] := "December"
> AmYArRaY[6] := DATE()
That sort of looks kind of like something resembling a C-ish language.
> (i.e., you don't get screwed with Upppercase, Lowercase syntax crap,
> its all the same array)
Then it's definitely not C.
> or,
> aCrap := {3.1415926,"3.14",date(),seconds(),"etcetera")
Nope, not C.
> ? aCrap[4] // kickls up a line, shows the seconds since midnite
Not sure that that means, but it's not C.
> For I = 1 to 1000000 // a simple loop and counter
> // do anything here
> Next
Not C at all.
> or
>
> For i = 1000000 to 1 skip -2
> // do anything backwards
> next
Looks like BASIC to me.
Ah... Maybe the "? aCrap[4]" above is like BASIC's "?" shorthand for PRINT.
> while lHellFreezesOver // any logical/boolean vrbl or expression
> // work away in here until time to exit
> EXIT
> end
Not C.
--
Kenneth Brody
Had you posted simple off topic language advocacy I wouldn't have
bothered responding. I in general am not interested in being the
topicality police, and sometimes offer off topic advice while also
advising people to look elsewhere for details. But to try and defend
a completely different language as topical to a C group because it is
a front end that in one implementation happens to produce C as topical
here is neither rational nor reasonable. Not a good approach to being
listened to IMHO.
-David
Not really.
> Or are you saying that Borland's C compiles all sorts of things that are
> *not* C ??
There are many translators from other languages to C. That doesn't make
those languages C, even though you eventually compile stuff that started
in them with a C compiler.
> But may you may wish to call it 'Hi C' for High-level C ??
It seems as though you have syntax which isn't C, which is used to create
C code, no?
-s
--
Copyright 2011, all wrongs reversed. Peter Seebach / usenet...@seebs.net
http://www.seebs.net/log/ <-- lawsuits, religion, and funny pictures
http://en.wikipedia.org/wiki/Fair_Game_(Scientology) <-- get educated!
I am not speaking for my employer, although they do rent some of my opinions.
Exactly.
> But xHarbour is absolutely like C !!
"Like" C is not the same thing as "is" C.
> aMyArray = ARRAY(12)
This is not like C. In C, there'd be a semicolon here.
> amyarray[1]="January" ; AMYARRAY[12] := "December"
> AmYArRaY[6] := DATE()
And you are using ":=" for assignment, which is not like C.
> (i.e., you don't get screwed with Upppercase, Lowercase syntax crap,
> its all the same array)
And this is absolutely, totally, unlike C, and contrary to the spirit of
C.
All the examples you show indicate that not only is this language not
C, but that it is actively hostile to the things that C programmers know
and work with. Case sensitivity of identifiers (with rare and specialized
exceptions) has been part of C since K&R and before, and a great deal
of C not only reflects this but *relies* on it.
Whatever you're peddling, it ain't C, and speaking as someone who quite
likes C, I can't easily imagine any programmer liking both this and C.
> On 2011-04-25, Mel Smith <med_cuto...@aol.com> wrote:
>> It's quite common for start-up languages to compile to C for this
>> reason. However the source language itself doesn't have to be remotely
>> like C, it could be from the Lisp family of languages or something
>> entirely of your own invention.
>
> Exactly.
The paragraph starting "It's quite common..." was written by Malcolm
McLean. Mel Smith (or his Usenet client) has not yet got the hang of
quoting text in replies so you can't tell from the '>' marks who said
what.
<snip>
--
Ben.
>> Exactly.
Argh! That's the second time in the last couple of days I've been bitten
by that (the other in a web forum, so it wasn't a usenet thing there).
So what? I will not try to copy Dan Pop's style, but you might benefit
from reading some of his posts. Your business application is not in
itself C. If someone using your application were to post questions here
about how to use it, based on the completely silly idea that because it
is written in C it _is_ C, he would obviously be in the wrong place.
> Or are you saying that Borland's C compiles all sorts of things that are
> *not* C ??
Besides the obvious that BCC also compiles things written in C++, a
language that is not C, you suffer from a confusion which, honestly, I
can't imagine any intelligent person having. Things written in C are
not C. There is a vast array of programming languages, editors, among
many other things, that are written in C and are not C.
Someone who has problems writing C code in implementing a BASIC
interpreter may have C questions. Someone having problems writing a
program for that BASIC does _not_ have a C question.
> See ??
See what? That you are hopelessly confused?
> But may you may wish to call it 'Hi C' for High-level C ??
No, it's not C at all. Get a clue.
>
He's already said he's not going to post here anymore.