Login
Username:

Password:

Remember me



Lost Password?

Register now!
Main Menu
Who is Online
7 user(s) are online (5 user(s) are browsing Forum)

Members: 0
Guests: 7

more...


Browsing this Thread:   1 Anonymous Users






Re: STRPTR and stdlib
#4
Home away from home
Home away from home


See User information
First thanks from ZunePaint author, that's one major goal for me, open sourcing my developments under AROS to inspire others.

Then regarding your question, as said mixing Amiga specifics with Ansi/Posix standards is a bit of additional work regarding casting to have a warning free compilation.

Posted on: 2018/7/20 10:25
 Top  Twitter  Facebook  Google Plus  Linkedin  Del.icio.us  Digg  Reddit  Mr. Wong 


Re: STRPTR and stdlib
#3
Quite a regular
Quite a regular


See User information
Thanks. So it's totally "normal" to see a bunch of casts to char * and const char * when calling clib string functions.

Posted on: 2018/7/19 15:14
 Top  Twitter  Facebook  Google Plus  Linkedin  Del.icio.us  Digg  Reddit  Mr. Wong 


Re: STRPTR and stdlib
#2
Home away from home
Home away from home


See User information
STRPTR is an Amiga specific definition defined in the original exec/types.h of AmigaOS includes and taken over by AROS for compatibility.
clib follows the ANSI standard which uses (const) char * as pointer to a string.

Posted on: 2018/7/17 19:29
......
 Top  Twitter  Facebook  Google Plus  Linkedin  Del.icio.us  Digg  Reddit  Mr. Wong 


STRPTR and stdlib
#1
Quite a regular
Quite a regular


See User information
Is somebody able to explain the reasoning behind STRPTR (and CONST_STRPTR) defined in exec/types.h. I imagine these would be useful for cross-platform development but then I see (or write myself) code to cast into char* or const char* to use clib functions like strlen.

Am I missing something fundamental?

Also a huge thank you to the Zune Paint authors. I'm finding the code to be very instructional on Zune/MUI.

Posted on: 2018/7/17 14:49
 Top  Twitter  Facebook  Google Plus  Linkedin  Del.icio.us  Digg  Reddit  Mr. Wong 







You can view topic.
You cannot start a new topic.
You cannot reply to posts.
You cannot edit your posts.
You cannot delete your posts.
You cannot add new polls.
You cannot vote in polls.
You cannot attach files to posts.
You cannot post without approval.
You cannot use topic type.
You cannot use HTML syntax.
You cannot use signature.
You cannot create PDF files.
You cannot get print page.

[Advanced Search]


Search
Top Posters
1 paolone
paolone
4462
2 nikolaos
nikolaos
4206
3 magorium
magorium
4095
4 phoenixkonsole
phoenixkonsole
3942
5 deadwood
deadwood
2917
6 ncafferkey
ncafferkey
2810
7 mazze
mazze
2222
8 Kalamatee
Kalamatee
2212
9 clusteruk
clusteruk
2114
Powered by XOOPS © 2001-2025 The XOOPS Project