Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old May 16th, 2005, 10:45 AM   #11
Infinite Recursion
Programming Guru
 
Infinite Recursion's Avatar
 
Join Date: Jul 2004
Location: United States
Posts: 3,467
Rep Power: 8 Infinite Recursion is on a distinguished road
Send a message via MSN to Infinite Recursion Send a message via Yahoo to Infinite Recursion
I can't recall if it was Sun or IBM that had that... Hopefully, I didn't through that mag away as I don't recall the name. I will look for it when I get home today.
__________________
http://jasonpowers.net

"There are a thousand hacking at the branches of evil to one who is striking at the root."
Infinite Recursion is offline   Reply With Quote
Old May 16th, 2005, 10:46 AM   #12
Ooble
I eat cake for breakfast.
 
Ooble's Avatar
 
Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9 Ooble is on a distinguished road
Cheers.
__________________
Me :: You :: Them
Ooble is offline   Reply With Quote
Old May 16th, 2005, 12:57 PM   #13
Nuticulus
Programmer
 
Nuticulus's Avatar
 
Join Date: May 2005
Location: England
Posts: 61
Rep Power: 4 Nuticulus is on a distinguished road
Quote:
Originally Posted by uman
something I would like is to have certain functions be declared as "value only" or something to that effect. These functions would treat all their pointer/reference arguments as const, and would not modify any statically-allocated variables. They couldn't be declared void, because that would be pointless.

These value only functions would also be able to be evaluated at compile-time if they were passed constant arguments! That way you could have something like this:
value int square(int i)
{
       return i*i;
}
const int squares[10];
for(int i = 0;i<10;i++)
{
        squares[i] = square(i);
}
the array "squares" should be completely evaluated and filled in at compile time. I don't know if good compilers can do this already. If they can, ignore me :-P
The closest we have to that is macros in C. Of course, it would be very hard to manage to pre-calculate those values at compile time, as the compiler would literally have to run the program to find out what the values of I would be, and subsequently do the math. If you think about it, the resulting code would be larger, as you have the precalculated values in the code. Now, that may be all well and good if you have only a few iterations of the function, but what about 1000, or 1000,000? Eeek.

I just felt like stamping on a dream today

My ideal language would manage memory without need for the programmer to interfere much with it. Of course, I'd like to see something like setting memory areas as non-executable, to prevent against buffer overflows, but that's a feature closer to the OS and hardware than a compiler. I'd also like to see a nice, standardised API available to interact with basic features of many operating systems, such as GUI making etc. It'd make portability so much easier. Of course, that's just like writing a little wrapper to abstract API x of platform y into something usable by all.

A lot of features I've asked for have been handled by dear old Python, but the main thing I'd like to see out of a programming language is something that's really optimised. Real power crunching code. Possibly optimised by the compiler itself (and I don't mean by omitting the frame pointer every so often).

It'd kick ass to find a language for newbies also, that doesn't frighten people off, and isn't spurned by more veteran coders. In many cases, coding newbies don't know what to do. If there was only one universal resolution as to what the ultimate beginner language was, then it'd solve 90% of the newbie coding problems I see on forums.

Alright, well that's my 2c.
Nuticulus is offline   Reply With Quote
Old May 16th, 2005, 11:06 PM   #14
iignotus
Professional Programmer
 
iignotus's Avatar
 
Join Date: Apr 2005
Location: Nowhere Special
Posts: 466
Rep Power: 4 iignotus is on a distinguished road
Send a message via AIM to iignotus
Quote:
It'd kick ass to find a language for newbies also, that doesn't frighten people off, and isn't spurned by more veteran coders. In many cases, coding newbies don't know what to do. If there was only one universal resolution as to what the ultimate beginner language was, then it'd solve 90% of the newbie coding problems I see on forums.
I had always wondered why that goal was so difficult to accomplish by many languages. It is an undeniable benefit to have the best of both worlds, so you know that most people would try to strive for it when creating a language.

But I've never understood why you couldn't have simple concepts tie into more complicated ones on different levels based on where you are as a programmer. There are many, many examples I'm sure, but the first that comes to mind is relaxed into strict typing. Why would it be so hard to do something like
mystring = "Hello";
mynumber = 25;
myitem = mystring + mynumber; // myitem contains "Hello25";
and then transition into something like this
char array mystring = "Hello";
short uint mynumber = 25;
myitem = mystring + mynumber; // myitem, specifically declared without types, is able to now contain "Hello25";
long uint myitem2 = mystring + mynumber; // would raise an error at compile time
when you're more experienced, for speed and a lower memory footprint? It seems like it would be ridiculously easy to implement... and yet, no language has that idea to my knowledge.

That's just one for-example of why I brought this topic up.
__________________
% rc4 hexkey < input > output
#define S ,t=s[i],s[i]=s[j],s[j]=t /* rc4 hexkey <file */
unsigned char k[256],s[256],i,j,t;main(c,v,e)char**v;{++v;while(++i)s[ 
i]=i;for(c=0;*(*v)++;k[c++]=e)sscanf((*v)++-1,"%2x",&e);while(j+=s[i]
+k[i%c]S,++i);for(j=0;c=~getchar();putchar(~c^s[t+=s[i]]))j+=s[++i]S;}
iignotus is offline   Reply With Quote
Old May 20th, 2005, 9:46 AM   #15
Infinite Recursion
Programming Guru
 
Infinite Recursion's Avatar
 
Join Date: Jul 2004
Location: United States
Posts: 3,467
Rep Power: 8 Infinite Recursion is on a distinguished road
Send a message via MSN to Infinite Recursion Send a message via Yahoo to Infinite Recursion
The language I mentioned in my prior response is MIT's Metaphor (an Article in my Optimize mag)

It takes a "story" inputed by the "programmer" and generates the code. If there is an interest in this, I will scan the magazine article and put it on here.
__________________
http://jasonpowers.net

"There are a thousand hacking at the branches of evil to one who is striking at the root."
Infinite Recursion is offline   Reply With Quote
Old May 20th, 2005, 2:07 PM   #16
iignotus
Professional Programmer
 
iignotus's Avatar
 
Join Date: Apr 2005
Location: Nowhere Special
Posts: 466
Rep Power: 4 iignotus is on a distinguished road
Send a message via AIM to iignotus
Quote:
Originally Posted by Infinite Recursion
The language I mentioned in my prior response is MIT's Metaphor (an Article in my Optimize mag)

It takes a "story" inputed by the "programmer" and generates the code. If there is an interest in this, I will scan the magazine article and put it on here.
I saw it on /. http://developers.slashdot.org/artic...623200&tid=156
__________________
% rc4 hexkey < input > output
#define S ,t=s[i],s[i]=s[j],s[j]=t /* rc4 hexkey <file */
unsigned char k[256],s[256],i,j,t;main(c,v,e)char**v;{++v;while(++i)s[ 
i]=i;for(c=0;*(*v)++;k[c++]=e)sscanf((*v)++-1,"%2x",&e);while(j+=s[i]
+k[i%c]S,++i);for(j=0;c=~getchar();putchar(~c^s[t+=s[i]]))j+=s[++i]S;}
iignotus is offline   Reply With Quote
Old May 20th, 2005, 2:11 PM   #17
Infinite Recursion
Programming Guru
 
Infinite Recursion's Avatar
 
Join Date: Jul 2004
Location: United States
Posts: 3,467
Rep Power: 8 Infinite Recursion is on a distinguished road
Send a message via MSN to Infinite Recursion Send a message via Yahoo to Infinite Recursion
Yup, the actual article that I saw in my mag (with screenshot, etc) is in a dedicated thread in the Application Programming - Misc forum.
__________________
http://jasonpowers.net

"There are a thousand hacking at the branches of evil to one who is striking at the root."
Infinite Recursion is offline   Reply With Quote
Old May 20th, 2005, 4:35 PM   #18
Ooble
I eat cake for breakfast.
 
Ooble's Avatar
 
Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9 Ooble is on a distinguished road
That's pretty damn sweet.
__________________
Me :: You :: Them
Ooble is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 6:07 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC