read.h 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. /* classes: h_files */
  2. #ifndef SCM_READ_H
  3. #define SCM_READ_H
  4. /* Copyright (C) 1995,1996,2000, 2006, 2008, 2009 Free Software Foundation, Inc.
  5. *
  6. * This library is free software; you can redistribute it and/or
  7. * modify it under the terms of the GNU Lesser General Public License
  8. * as published by the Free Software Foundation; either version 3 of
  9. * the License, or (at your option) any later version.
  10. *
  11. * This library is distributed in the hope that it will be useful, but
  12. * WITHOUT ANY WARRANTY; without even the implied warranty of
  13. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  14. * Lesser General Public License for more details.
  15. *
  16. * You should have received a copy of the GNU Lesser General Public
  17. * License along with this library; if not, write to the Free Software
  18. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
  19. * 02110-1301 USA
  20. */
  21. #include "libguile/__scm.h"
  22. #include "libguile/options.h"
  23. /* SCM_LINE_INCREMENTORS are the characters which cause the line count to
  24. * be incremented for the purposes of error reporting. This feature
  25. * is only used for scheme code loaded from files.
  26. *
  27. * SCM_WHITE_SPACES are other characters which should be treated like spaces
  28. * in programs.
  29. */
  30. #define SCM_LINE_INCREMENTORS '\n'
  31. #ifdef MSDOS
  32. # define SCM_SINGLE_SPACES ' ':case '\r':case '\f': case 26
  33. #else
  34. # define SCM_SINGLE_SPACES ' ':case '\r':case '\f'
  35. #endif
  36. #define SCM_WHITE_SPACES SCM_SINGLE_SPACES: case '\t'
  37. SCM_API SCM scm_sym_dot;
  38. SCM_API SCM scm_read_options (SCM setting);
  39. SCM_API SCM scm_read (SCM port);
  40. SCM_API size_t scm_read_token (int ic, SCM * tok_buf, SCM port, int weird);
  41. SCM_API SCM scm_read_hash_extend (SCM chr, SCM proc);
  42. SCM_INTERNAL char *scm_i_scan_for_encoding (SCM port);
  43. SCM_API SCM scm_file_encoding (SCM port);
  44. SCM_INTERNAL void scm_i_input_error (const char *func, SCM port,
  45. const char *message, SCM arg)
  46. SCM_NORETURN;
  47. SCM_INTERNAL void scm_init_read (void);
  48. #endif /* SCM_READ_H */
  49. /*
  50. Local Variables:
  51. c-file-style: "gnu"
  52. End:
  53. */