OK, turing.

<- leave blank

Mon Jun 11 08:51:58 EDT 2018

goroutine 74 [running]:
bitbucket.org/henesy/glenda/x/mux.Listener()
	/home/seh/gopath/src/bitbucket.org/henesy/glenda/x/mux/commits.go:24 +0xb8
created by bitbucket.org/henesy/glenda/x/mux.(*Configuration).Init
	/home/seh/gopath/src/bitbucket.org/henesy/glenda/x/mux/config.go:47 +0x118


Sun Jun 10 17:34:28 EDT 2018


Fri Jun 8 21:32:57 EDT 2018

#include <u.h>
#include <libc.h>

/* https://stackoverflow.com/a/1644898 */
#define E(...) if(debug > 0) fprint(2,__VA_ARGS__)
#define F(...) {if(debug > 0) fprint(2,__VA_ARGS__);}
#define D(...) do { if (debug > 0) fprint(2, __VA_ARGS__); } while (0)

void
main(int, char **)
{
	int debug = 1, i = 1;

	if (0 == 1)
		D("testing debug: %d, i: %d\n", debug, i);
	else
		D("doing the else debug: %d, i: %d\n", debug, i);
	F("doing the F debug: %d, i: %d\n", debug, i);
	exits(nil);
}


Fri Jun 8 21:18:01 EDT 2018
 The distribution of work between the compiler and loader is unusual.  The
 compiler integrates preprocessing, parsing, register allocation, code generation
 and some assembly.  Combining these tasks in a single program is part of the
 reason for the compiler’s efficiency.  The loader does instruction selection,
 branch folding, instruction scheduling, and writes the final executable.  There
 is no separate C preprocessor and no assembler in the usual pipeline.  Instead
 the intermediate object file (here a .2 file) is a type of binary assembly
 language.  The instructions in the intermediate format are not exactly those in
 the machine.  For example, on the 68020 the object file may specify a MOVE
 instruction but the loader will decide just which variant of the MOVE instruction
 — MOVE immediate, MOVE quick, MOVE address, etc.  — is most efficient.

Fri Jun 8 20:35:39 EDT 2018
void
dprint(int debug, char *fmt, ...)
{
	va_list ap;

	USED(fmt);
	if(debug > 0) {
		va_start(ap, fmt);
		vfprint(2, fmt, ap);
		va_end(ap);
	}
}

Fri Jun 8 20:31:53 EDT 2018
#include <u.h>
#include <libc.h>

#define D(...) if(debug == 1) fprint(2, __VA_ARGS__)

void
main(int, char **)
{
	int debug = 1, i = 1;

	/* Is it possible to move the 2 fd argument below into the macro */
	D("testing debug: %d, i: %d\n", debug, i);
	exits(nil);
}



Fri Jun 8 20:31:50 EDT 2018


Fri Jun 8 20:17:36 EDT 2018

#include <u.h>
#include <libc.h>

#define D if(debug == 1) fprint

void
main(int, char **)
{
	int debug = 1, i = 1;

	/* Is it possible to move the 2 fd argument below into the macro */
	D(2, "testing debug: %d, i: %d\n", debug, i);
	exits(nil);
}


Fri Jun 8 20:12:01 EDT 2018
test


Fri Jun 8 14:47:33 EDT 2018
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x6add8b]

goroutine 74 [running]:
bitbucket.org/henesy/glenda/x/mux.Listener()
	/home/seh/gopath/src/bitbucket.org/henesy/glenda/x/mux/commits.go:23 +0x8b
created by bitbucket.org/henesy/glenda/x/mux.(*Configuration).Init
	/home/seh/gopath/src/bitbucket.org/henesy/glenda/x/mux/config.go:47 +0x118

Fri Jun 8 08:47:28 EDT 2018
#!/bin/rc
file = ()
filename = '<stdin>'
if(~ $#* 1){
  file = $1
  filename = $1
}
awk '{print NR, $0}' $file |
sed -n 's/^([0-9]+) (08MAY2018_([0-9]+):([0-9]+):([0-9]+)).*atime=([0-9]+).*/\1 \2
\3\4\5 \6/p' |
datecmp |
awk '{print("'$filename':" $0)}'


prev | next