Skip to content

Instantly share code, notes, and snippets.

Avatar
🎯
Focusing

Francesco Ceccon fracek

🎯
Focusing
View GitHub Profile
View libgit2.intr
let opts = initialize-options (<git-repository-init-options>)
version,
flags,
working-directory => workdir-path,
description
end;
View libgit2.intr
define method git-repository-init
(path :: <string>,
#key bare? :: <boolean> = #f,
flags :: false-or(<integer>) = #f,
mode :: false-or(<integer>) = #f,
working-directory :: false-or(<string>) = #f,
description :: false-or(<string>) = #f,
template-path :: false-or(<string>) = #f,
initial-head :: false-or(<string>) = #f,
View multiple-collection.dylan
// Given a function that takes an argument and returns n values,
// this helper method applies the function point-by-point to a vector,
// returning n vectors of corresponding results.
define function fake-values (x, #rest r) // HACK: TO AVOID COMPILER BUG
apply(values, x, r)
end function;
View collection.dylan
define method size (collection :: <collection>) => (result :: <integer>)
for (item in collection, size :: <integer> from 0)
finally
size;
end for
end method size;
View non-local-exit.dylan
define method analyze-non-local-exits (lambda :: <&lambda>) => ()
let changed? = #f;
for (entry in lambda.environment.entries)
changed? := analyze-entry(entry);
end for;
changed?
end method;
View convert-loops.dylan
for (fc in object.for-clauses, i from 0)
let (f, l) = generate-step-7(env, states[i]);
let (f, l) = join-2x2!(first, last, f, l); first := f; last := l;
end;
View compilation-driver.dylan
define method check-local-bindings
(description :: <project-library-description>) => ()
for-library-method (#f, $compilation of m in description)
// Accessor methods don't have a body. Without this check, for-computations
// crashes.
if (~instance?(m, <&accessor-method>))
/*
for-computations (c in m)
if (c.temporary & ~c.temporary.used? & c.temporary.named?)
View boehm-collector.c
if (mrq) { \
if (mrep_size_slot) { \
object[mrep_size_slot] = (void*)((mrep_size << 2) + 1); \
} \
} \
// =>
if (mrq) { \
if (mrep_size_slot) { \
object[mrep_size_slot] = I(mrep_size); \
View imap.dylan
for (item in msg-att.mailimap_msg_att$att-list)
let msg = pointer-cast(<mailimap-msg-att-item*>, item);
unless (msg.mailimap_msg_att_item$att-type = $MAILIMAP-MSG-ATT-ITEM-STATIC)
return (msg.mailimap_msg_att_item$att-data.anonymous-326$att-static.mailimap_msg_att_static$att-data.anonymous-339$att-body-section.mailimap_msg_att_body_section$sec-body-part)
end;
end for;
View etpan.dylan
/* Ignoring declaration for {<variable-declaration> #x00998EE0} "mailimap-extension-acl"*/
define C-pointer-type <clistcell-s*> => <clistcell-s>;
define C-struct <clistcell-s>
slot clistcell_s$data :: <C-void*>;
slot clistcell_s$previous :: <clistcell-s*>;
slot clistcell_s$next :: <clistcell-s*>;
end;
define constant <clistcell> = <clistcell-s>;