1 /*-------------------------------------------------------------------------
3 _gptrput.c :- put value for a generic pointer
5 Written By - Sandeep Dutta . sandeep.dutta@usa.net (1999)
7 This library is free software; you can redistribute it and/or modify it
8 under the terms of the GNU Library General Public License as published by the
9 Free Software Foundation; either version 2, or (at your option) any
12 This library is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU Library General Public License for more details.
17 You should have received a copy of the GNU Library General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21 In other words, you are welcome to use, share and improve this program.
22 You are forbidden to forbid anyone else to use, share and improve
23 what you give them. Help stamp out software-hoarding!
24 -------------------------------------------------------------------------*/
26 /* the return value is expected to be in acc, and not in the standard
27 * location dpl. Therefore we choose return type void here: */
29 _gptrput (char *gptr, char c)
31 gptr; c; /* hush the compiler */
36 ; depending on the pointer type acc. to SDCCsymt.h
46 dec a ; 4 skip generic pointer
52 ; store into near space
88 ; depending on the pointer type acc. to SDCCsymt.h
98 dec a ; 4 skip generic pointer
104 ; store into near space