Displaying 8 results from an estimated 8 matches for "first_char".
2007 Dec 29
5
./script/story command
...LE__) + "/..")
STORIES_PATH = "#{ROOT_PATH}/stories/scenarios"
STEP_MATCHERS_PATH = "#{ROOT_PATH}/stories/steps"
HELPER_PATH = "#{ROOT_PATH}/stories/helper"
def self.run
self.new.run
end
def run
if ARGV.empty? && first_char = using_stdin?
setup_and_run_story((first_char + STDIN.read).split("\n"))
elsif ARGV.empty?
run_story_files(all_story_files)
else
run_story_files(ARGV)
end
end
def all_story_files
Dir["#{STORIES_PATH}/**/*.story"].uniq
end
def using_st...
2012 Jan 25
2
[PATCH 1/2] gobject: Allow RConstOptString to return an error
...2 insertions(+), 6 deletions(-)
diff --git a/generator/generator_gobject.ml b/generator/generator_gobject.ml
index 4779f23..2b88274 100644
--- a/generator/generator_gobject.ml
+++ b/generator/generator_gobject.ml
@@ -37,10 +37,6 @@ let camel_of_name flags name =
a ^ String.uppercase (Str.first_chars b 1) ^ Str.string_after b 1
) "" (Str.split (regexp "_") name)
-let returns_error = function
- | RConstOptString _ -> false
- | _ -> true
-
let generate_gobject_proto name ?(single_line = true)
(ret, args, optargs) flags =
let...
2012 Jan 20
11
[PATCH 01/10] Revert "Revert "generator: Add CamelName flag""
This reverts commit 3f6ca541c7b24d4c86688a509582cb41a7e0078c.
The original commit was reverted prematurely.
---
generator/generator_actions.ml | 10 +++++-----
generator/generator_checks.ml | 5 +++++
generator/generator_types.ml | 3 +++
3 files changed, 13 insertions(+), 5 deletions(-)
diff --git a/generator/generator_actions.ml b/generator/generator_actions.ml
index
2012 Jan 17
3
GObject bindings
This is the first iteration of the GObject bindings. I have 'kicked the tyres'
on these, meaning I have ensured that a bunch of basic manual tests work as
expected. I'm in the process of adding more comprehensive tests.
Here's an example simple javascript program which uses these bindings:
===
const Guestfs = imports.gi.Guestfs;
print('Starting');
var g = new
2017 Jun 21
6
RFC: Cleaning up the Itanium demangler
...;has_array() || member_type->has_function())
+ s += ")";
+ member_type->print_right(s);
+ }
+};
+
+struct node_or_string
+{
+ const void* first;
+ const void* second;
+
+public:
+ /* implicit */ node_or_string(string_ref str)
+ {
+ const char* first_char = str.begin();
+ const char* second_char = str.end();
+ if (second_char == nullptr) {
+ assert(first_char == second_char);
+ ++first_char, ++second_char;
+ }
+ first = static_cast<const void*>(first_char);
+ second = static_cast<cons...
2020 Mar 24
1
[PATCH libnbd v3] Add Go language bindings (golang) (RHBZ#1814538).
This feature is roughly finished now, although it needs a few more
tests and some examples.
It's pretty much up to par with all the other bindings, but it lacks a
completely safe AIO buffer. It won't stop you from freeing the buffer
too early) because golang's GC inexplicably lacks a way to declare a
root from C. I can probably do it with a global variable and ref
counting on the
2017 Sep 22
27
[PATCH v3 00/22] Replace almost all uses of the Str module with PCRE.
v1:
https://www.redhat.com/archives/libguestfs/2017-September/msg00135.html
v2:
https://www.redhat.com/archives/libguestfs/2017-September/msg00158.html
v3 is almost identical to v2, but I have added 4 extra commits to
almost finish the job of replacing Str everywhere possible (note it's
not possible to replace Str in common/mlstdutils or the generator
because those are pure OCaml).
As
2020 Mar 25
3
[PATCH libnbd v4] Add Go language bindings (golang) (RHBZ#1814538).
Now runs a complete set of tests, notably including the AIO test.
File descriptors are passed in and out as plain ints (instead of
*os.File) for a couple of reasons: (1) We have to pass the plain int
to syscall.Select. (2) Turning an fd into an os.File causes golang to
set the blocking flag which is deeply unhelpful.
Rich.