1. DNS (Euphoria 4.0)

The manual is a little more than.. trivial to understand (I'm not a very experienced coder beyond euphoria, and it's been a while.) But I'd like to do a simple DNS lookup, and I don't quite understand the syntax required. I'd like to implement a simplistic IRC client, providing I can figure out how to work these new bits and pieces.

new topic     » topic index » view message » categorize

2. Re: DNS (Euphoria 4.0)

Kebs said...

The manual is a little more than.. trivial to understand (I'm not a very experienced coder beyond euphoria, and it's been a while.) But I'd like to do a simple DNS lookup, and I don't quite understand the syntax required. I'd like to implement a simplistic IRC client, providing I can figure out how to work these new bits and pieces.

I can't really help you with DNS stuff (networking is not my strong point), but Jeremy Cowgar wrote an IRC demo for his EuIUP library.

You can see the code here:

https://bitbucket.org/jcowgar/euiup/src/9a4107e7fd3c/demos/euchat.ex

Obviously, it uses EuIUP, but it's pretty small, and should help you get going.

Matt

new topic     » goto parent     » topic index » view message » categorize

3. Re: DNS (Euphoria 4.0)

If I'm understanding correctly, the syntax for dns.e and so on are <nameofincludeOrinclude_as>:<function>. Is this correct?

new topic     » goto parent     » topic index » view message » categorize

4. Re: DNS (Euphoria 4.0)

Kebs said...

If I'm understanding correctly, the syntax for dns.e and so on are <nameofincludeOrinclude_as>:<function>. Is this correct?

In general, yes. In euphoria 4.0, files can also declare a default namespace (and built-in functions use the built in eu namespace). The standard library files do this. The namespace qualifier is not generally required, except to deconflict two symbols with the same name. However, the qualifier can be helpful when reading code.

Matt

new topic     » goto parent     » topic index » view message » categorize

5. Re: DNS (Euphoria 4.0)

I managed to figure some of it out. I slapped together a custom include with basic DNS lookup functions that return just the IP, but now I get the following errors:

c:\euphoria\bin\nettest.ex:18 <0074>:: Errors resolving the following references: nettest.ex (18): lookup

printf(2, "%s", {lookup(address)})

If I can just get this ironed out, I think I can carry on.

EDIT: I forgot entirely about the global/export option. Problem solved.

new topic     » goto parent     » topic index » view message » categorize

6. Re: DNS (Euphoria 4.0)

Kebs said...

The manual is a little more than.. trivial to understand (I'm not a very experienced coder beyond euphoria, and it's been a while.) But I'd like to do a simple DNS lookup, and I don't quite understand the syntax required. I'd like to implement a simplistic IRC client, providing I can figure out how to work these new bits and pieces.


Good luck with that. I wrote an Euphoria irc plugin for mirc, two standalone Euphoria irc clients (one used mirc as a gui), and yet, i'm...

useless

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu