red / code Goto Github PK
View Code? Open in Web Editor NEWThis repository contains curated code written in Red and its dialects.
This repository contains curated code written in Red and its dialects.
Compiling to native code...
*** Compilation Error: argument type mismatch on calling: red/stack/mark-func
*** expected: [pointer! [integer!]], found: [none]
*** in file: %/c/Red2/code/Library/SQLite/SQLite3.red
*** at line: 332
*** near: [
set-path* eval-path _context/get ~system as cell! ~script as
]
The terminal process terminated with exit code: 1
Windows | red-063.exe | 1.1 MB -- | -- | -- sha256:ย 105d0f7b009a802a35a636c5dbedc69e89477fd62b6ba77690845fd78d436171
Tried red-22mar17-0739930.exe, but it didn't work for me for quite some time now.
At least on W7, it shows nothing - only white window.
Line 55
Line 55 in 8bc2617
img/image: img/image
for it to work
Hello.
OS: Windows 10
Red version: 0.6.4
ZeroMQ version: 4.3.2
I'm try to start ZeroMQ socket(server?) from red(not Red/System), but can't compile this gist:
Compiling to native code...
*** Warning: handle! macro in R/S is redefined
*** Compilation Error: argument type mismatch on calling: exec/zmq/socket
*** expected: [pointer! [byte!]], found: [pointer! [integer!]]
*** in file: %/D/Dima/projects/red-ipython/red/src/kernel.red
*** in function: exec/start-server
*** at line: 381
*** near: [ctx 4
print-line ["ZMQ Context: " ctx]
print-line ["ZMQ Responder: " responder]
r: zmq/bind
]
It's can be fixed, with changes on this line from
ctx_new: "zmq_ctx_new" [ return: [handle!]]
to
ctx_new: "zmq_ctx_new" [ return: [byte-ptr!]]
and after this change, it's compile and server starts. I'm not tested yet this with client requests.
I can prepare PR with this fix, if it's ok.
There's a placeholder col header with #" " as the text, which to word! doesn't like when combined with a numeric digit to create the cell ref name. If you replace [#" "] with [#"_"]for now, it will work again.
I was really excited to hear about this language because I had envisioned something in the past, however nothing will run on my macbook air with the red-061binary.
For instance, when I try to run the calculator demo I get:
*** Script Error: view has no value
*** Where: catch
The calculator demo cannot run anymore.
https://github.com/red/code/blob/master/Showcase/calculator.red
Here is the error:
>> do https://raw.githubusercontent.com/red/code/master/Showcase/calculator.red
*** Script Error: VID - invalid syntax at: [50x40 [clear f/text] f:]
*** Where: do
*** Stack: do-file
From the console, run mandelbrot.red
Now click on Draw
.
Now close the GUI window before drawing is complete.
=> The console display error
*** View Error: CreateWindowEx failed!
*** Script Error: path none is not valid for none! type
*** Where: eval-set-path
*** Stack: view do-events do-actor do-safe mandelbrot do-events eval-set-path
The = button does not work. Previous version used to work.
As the last commit removed the spaces around the text of the operators, the typed formula cannot be parsed anymore when attempting to load it.
Possible fix could be to reintroduce the spaces before loading the formula:
formula: copy f/text
replace/all formula "+" " + "
replace/all formula "-" " - "
replace/all formula "/" " / "
replace/all formula "*" " * "
calculation: form math load formula
C:/Users/XX/red-27may17-5243005.exe -c c:\Users\XX\red\code\Scripts\mandelbrot-fast.red
>>
-=== Red Compiler 0.6.2 ===-
Compiling c:\Users\XX\red\code\Scripts\mandelbrot-fast.red ...
Compiling libRedRT...
...compilation time : 1436 ms
Compiling to native code...
...compilation time : 42575 ms
...linking time : 526 ms
...output file size : 894976 bytes
...output file : C:\Users\XX\red\code\libRedRT.dll
...compilation time : 52 ms
Target: MSDOS
Compiling to native code...
*** Compilation Error: undefined symbol: red/image/acquire-buffer
*** in file: %/c/Users/XX/red/code/Scripts/mandelbrot-fast.red
*** in function: exec/fast-mandelbrot
*** at line: 332
*** near: [image/acquire-buffer img :handle
while [iy < height] [
ix: 0.0
while [ix < width] [
x: xmin + ((xmax - xmin) * ix / (width - 1.0))
y: ymin + ((ymax - ymin) * iy / (height - 1.0))
i: mandelbrot-iter x y iterations
pix/value: either i > iterations [-16777216] [
c: 3.0 * (log-2 as float! i) / log-2 as float! (iterations - 1)
case [
c < 1.0 [-16777216 or (255 and (as integer! 255.0 * c) << 16)]
c < 2.0 [-65536 or (255 and (as integer! 255.0 * (c - 1.0)) << 8)]
true [-256 or (255 and (as integer! 255.0 * (c - 2.0)))]
]
]
pix: pix + 1
ix: ix + 1.0
]
iy: iy + 1.0
]
image/release-buffer img
]
I was trying to compile "SQLite3.red" using: red-064 -c SQLite3.red in Windows 10 OS, when it ended with:
Compiling to native code...
*** Loading Error: file access error: %definitions.reds
*** in file: %/c/.../Programming/Rebol/RED/SQLite/Oldies/SQLite3.reds
*** at line: 15
I found the 'definitions.reds' file in 'red/code - library/OS' and added it to the same directory as the SQLite3.red I was trying to compile, but I am still getting the error message.
Any help would be appreciated. TIA
(Background: I have written a nearly complete accounting system in Rebol3 {many thousands of lines of Rebol3 code} and it uses MySQL with the DB on a remote server. It works okay, but I wanted to start converting it to RED and SQLite.
I've been wanted to move to RED for years but still waiting for 'Network I/O' till I found this SQLite.red)
I am trying to compile the /Library/SQLite/SQLite3-test.red file and getting this error - "Compilation Error: undefined symbol: zero fill". Any advice?
Here is how I am trying to run the SQLite example and full error output -
$ ../../red-063 -c ../Library/SQLite/SQLite3-test.red
-=== Red Compiler 0.6.3 ===-
Compiling /Users/ajinkya/Downloads/code/Library/SQLite/SQLite3-test.red ...
...using libRedRT built on 12-Sep-2017/19:46:25-5:00
...compilation time : 86 ms
Target: Darwin
Compiling to native code...
*** Compilation Error: undefined symbol: zerofill
*** in file: %/Users/ajinkya/Downloads/code/Library/SQLite/SQLite3.red
*** at line: 9166
*** near: [
zerofill dbs-head dbs-tail
close-dbs: func [
/local
p [pointer! [integer!]]
] [
p: dbs-head
while [p < dbs-tail] [
if p/value <> 0 [
print-line ["closing db: " as pointer! [integer!] p/value]
sqlite3_close as pointer! [integer!] p/value
p/value: 0
]
p: p + 1
]
]
get-db-ptr:
]
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.