[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex()
From: |
Sean Conner |
Subject: |
Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex() |
Date: |
Thu, 30 Aug 2012 17:58:47 -0400 |
User-agent: |
Mutt/1.4.1i |
It was thus said that the Great grischka once stated:
> Sean Conner wrote:
> > I do not like this idea, and here's why: it produces a function that
> > does
> >two different things depending upon one parameter:
>
> Count. It is three different things.
>
> > In both cases, it returns the number of bytes required to relocate
> > the code.
>
> No.
Let me amend my previous statement on this---you are correct. And it's
way worse than I expected. tcc_relocate_ex() returns the number of bytes
iff ptr is NULL; otherwise it returns 0 on success and -1 on an error.
Somehow, I get the feeling that changing tcc_relocate_ex() to
int tcc_relocate_ex(TCCState *state,void *ptr,size_t *psize);
would be an uphill battle.
-spc
- Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex(), (continued)
Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex(), Jared Maddox, 2012/08/29
Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex(), Sean Conner, 2012/08/30
Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex(), grischka, 2012/08/30
Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex(), Sean Conner, 2012/08/30
Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex(),
Sean Conner <=
Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex(), grischka, 2012/08/31
Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex(), Sean Conner, 2012/08/31
Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex(), grischka, 2012/08/31
Re: [Tinycc-devel] tcc_relocate() and tcc_relocate_ex(), Sean Conner, 2012/08/31