#ifndef RBIMPL_ATTR_CONST_H /*-*-C++-*-vi:se ft=cpp:*/ #define RBIMPL_ATTR_CONST_H /** * @file * @author Ruby developers * @copyright This file is a part of the programming language Ruby. * Permission is hereby granted, to either redistribute and/or * modify this file, provided that the conditions mentioned in the * file COPYING are met. Consult the file for details. * @warning Symbols prefixed with either `RBIMPL` or `rbimpl` are * implementation details. Don't take them as canon. They could * rapidly appear then vanish. The name (path) of this header file * is also an implementation detail. Do not expect it to persist * at the place it is now. Developers are free to move it anywhere * anytime at will. * @note To ruby-core: remember that this header can be possibly * recursively included from extension libraries written in C++. * Do not expect for instance `__VA_ARGS__` is always available. * We assume C99 for ruby itself but we don't assume languages of * extension libraries. They could be written in C++98. * @brief Defines #RBIMPL_ATTR_CONST. */ #include "ruby/internal/compiler_since.h" #include "ruby/internal/has/attribute.h" #include "ruby/internal/has/declspec_attribute.h" /** Wraps (or simulates) `__attribute__((const))` */ #if RBIMPL_HAS_ATTRIBUTE(const) # define RBIMPL_ATTR_CONST() __attribute__((__const__)) #elif RBIMPL_HAS_DECLSPEC_ATTRIBUTE(noalias) # /* If a function can be a const, that is also a noalias. */ # define RBIMPL_ATTR_CONST() __declspec(noalias) #elif RBIMPL_COMPILER_SINCE(SunPro, 5, 10, 0) # define RBIMPL_ATTR_CONST() _Pragma("no_side_effect") #else # define RBIMPL_ATTR_CONST() /* void */ #endif /** Enables #RBIMPL_ATTR_CONST if and only if. ! #RUBY_DEBUG. */ #if !defined(RUBY_DEBUG) || !RUBY_DEBUG # define RBIMPL_ATTR_CONST_UNLESS_DEBUG() RBIMPL_ATTR_CONST() #else # define RBIMPL_ATTR_CONST_UNLESS_DEBUG() /* void */ #endif #endif /* RBIMPL_ATTR_CONST_H */ logtreecommitdiff
path: root/test/pathname
AgeCommit message (Expand)Author
2014-11-13* test/lib/envutil.rb: Moved from test/ruby/.akr
2014-09-15pathname.rb: fix a Pathname#relative_path_from crash onnobu
2014-09-04* test/pathname/test_pathname.rb: added testcase for Pathname#mountpoint.hsbt
2014-06-28* ext/pathname/pathname.c (path_birthtime): New method,akr
2014-05-05* ext/pathname/lib/pathname.rb (cleanpath_aggressive): make allakr
2014-05-05* ext/pathname/lib/pathname.rb (Pathname#/): Aliased to Pathname#+.akr
2014-04-02Fix error with empty args.kazu
2014-03-25remove unnecessary unshiftkazu
2014-03-04* ext/pathname/lib/pathname.rb (Pathname#find): add "ignore_error"ktsj
2014-02-16* test/pathname/test_pathname.rb: use File.exist? instead of File.exists?hsbt
2013-04-04* ext/pathname/pathname.c (path_write): New method.akr
2012-02-09* test/pathname/test_pathname.rb (test_binread): add assertion tonagachika
2012-02-08* test/pathname/test_pathname.rb: not read but binread.naruse
2012-01-25* file.c (rb_enc_path_next, rb_enc_path_skip_prefix)nobu
2011-11-19* lib/pathname.rb (Pathname#find): return an enumerator ifakr
2011-06-15* test/ruby/test_io.rb (test_copy_stream_socket): wait a child processakr
2011-02-12* lib/test/unit.rb (assert_include): add alias.nobu
2010-10-29* test/pathname/test_pathname.rb (TestPathname#test_grpowned?): theakr
2010-09-20* test/pathname/test_pathname.rb (TestPathname#test_mkdir): fix typo.kazu
2010-09-15* ext/pathname/pathname.c (path_mkdir): Pathname#mkdir translatedakr
2010-09-14* ext/pathname/pathname.c (path_s_getwd): Pathname.getwd andakr
2010-09-13* ext/pathname/pathname.c (path_s_glob): Pathname.glob translatedakr
2010-08-29* test/pathname/test_pathname.rb (test_expand_path): should treat drive letter.usa
2010-08-23* ext/pathname/pathname.c (path_each_line): Pathname#each_lineakr
2010-08-20* ext/pathname/pathname.c (path_expand_path): Pathname#expand_pathakr
2010-08-16* ext/pathname/pathname.c (path_basename): Pathname#basename translatedakr
2010-08-09* ext/pathname/pathname.c (path_open): Pathname#openakr
2010-08-08fix a test name.akr
2010-08-07* ext/pathname/pathname.c (path_fnmatch): Pathname#fnmatch andakr
2010-08-07* ext/pathname/pathname.c (path_lchown): Pathname#lchown translatedakr
2010-08-07* ext/pathname/pathname.c (path_sub_ext): don't clobber shared string.nobu
2010-08-07* test/ruby/envutil.rb (assert_normal_exit): use assert. fixakr
2010-08-03add tests.akr
2010-07-28add a test.akr
2010-03-07* file.c: add optional basedir argument for realpath/realdirpath.akr
2009-03-17* lib/pathname.rb (Pathname#sub): set $~ in block.binding.akr
2009-01-30* lib/pathname.rb (Pathname#realdirpath): new method.akr
2009-01-29add tests.akr
2008-10-02Back out the previous change after miniunit import.knu
2008-09-26* test/pathname/test_pathname.rb: Fix use of deprecated methods.knu
2008-09-23* lib/pathname.rb (each_filename): return Enumerator if no blockmame
2008-02-13* lib/pathname.rb (Pathname#sub_ext): new method. [ruby-list:44608]akr