PureBasic 5.40 LTS beta 10 is out !

Developed or developing a new product in PureBasic? Tell the world about it.
User_Russian
Addict
Addict
Posts: 1516
Joined: Wed Nov 12, 2008 5:01 pm
Location: Russia

Re: PureBasic 5.40 LTS beta 1 is out !

Post by User_Russian »

Fred wrote:This version introduce a new "import" resident file format, which uses an Import/EndImport block and create a file from it. It replaces the old ".pbl" format which is no more supported, and allow imported function arguments to be typed with pseudotype and more.
Please, make small example.
Thank you.
User avatar
Shield
Addict
Addict
Posts: 1021
Joined: Fri Jan 21, 2011 8:25 am
Location: 'stralia!
Contact:

Re: PureBasic 5.40 LTS beta 1 is out !

Post by Shield »

Sounds like great additions. :)

Code: Select all

- Added Literal string escape support with the '~' operator (ex: a$ = ~"Hello\nWorld\n")
Well geez, freaking finally...
Image
Blog: Why Does It Suck? (http://whydoesitsuck.com/)
"You can disagree with me as much as you want, but during this talk, by definition, anybody who disagrees is stupid and ugly."
- Linus Torvalds
Fred
Administrator
Administrator
Posts: 18153
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: PureBasic 5.40 LTS beta 1 is out !

Post by Fred »

User_Russian wrote:
Fred wrote:This version introduce a new "import" resident file format, which uses an Import/EndImport block and create a file from it. It replaces the old ".pbl" format which is no more supported, and allow imported function arguments to be typed with pseudotype and more.
Please, make small example.
Thank you.
Just do an import block:

Code: Select all

Import "test.lib"
  yourfunction_() as "yourfunction"
EndImport
And then use the command line compiler:

Code: Select all

pbcompiler test.pb --import "purebasichome/purelibraries/windows/yourfile.imp"
It should now be available as native imported function.
User_Russian
Addict
Addict
Posts: 1516
Joined: Wed Nov 12, 2008 5:01 pm
Location: Russia

Re: PureBasic 5.40 LTS beta 1 is out !

Post by User_Russian »

How to create from pbi-file, lib and imp file? Or something I have misunderstood?
supercdfr
User
User
Posts: 54
Joined: Tue Mar 16, 2010 9:28 pm

Re: PureBasic 5.40 LTS beta 1 is out !

Post by supercdfr »

A little error in the help file, on the "migration from 5.30 to 5.40", section CRC32FileFingerprint(): code change .

There was indicate :

; New
UseCR32FingerPrint()

Instead of :

; New
UseCRC32FingerPrint()
freak
PureBasic Team
PureBasic Team
Posts: 5940
Joined: Fri Apr 25, 2003 5:21 pm
Location: Germany

Re: PureBasic 5.40 LTS beta 1 is out !

Post by freak »

User_Russian wrote:Thank you for release. :) :)

Why need function UnescapeString() if without it working?

Code: Select all

Debug UnescapeString(~"Test=\"Hello\".")
Debug ~"Test=\"Hello\"."
You don't need it for literals. The ~"" already handles the unescaping as you noted.

The function is for doing your own escaping/unescaping if you want. For example:

Code: Select all

; Lets  say this comes from an EditorGadget() or similar, so it can contain newline and such
Something$ = ...

; Add escape sequences to make it a single-line string. Then store it in preferences
WritePreferenceString(Key$, EscapeString(Something$))

; Later read it back and remove escapes
Something$ = UnescapeString(ReadPreferenceString(Key$, ""))
quidquid Latine dictum sit altum videtur
c4s
Addict
Addict
Posts: 1981
Joined: Thu Nov 01, 2007 5:37 pm
Location: Germany

Re: PureBasic 5.40 LTS beta 1 is out !

Post by c4s »

Awesome list of new features... thank you very much! 8)
If any of you native English speakers have any suggestions for the above text, please let me know (via PM). Thanks!
Trond
Always Here
Always Here
Posts: 7446
Joined: Mon Sep 22, 2003 6:45 pm
Location: Norway

Re: PureBasic 5.40 LTS beta 1 is out !

Post by Trond »

freak wrote:You don't need it for literals. The ~"" already handles the unescaping as you noted.
The example in the help file is misleading.

Code: Select all

Debug UnescapeString(~"Test=\"Hello\".") ; misleading
Debug UnescapeString("Test=\" + #DOUBLEQUOTE$ + "Hello\" + #DOUBLEQUOTE$ +".") ; correct
Captn. Jinguji
User
User
Posts: 94
Joined: Sun Oct 24, 2004 9:25 am

Re: PureBasic 5.40 LTS beta 1 is out !

Post by Captn. Jinguji »

Thank you, PB Team, for making this new version.

Did I miss something, or what was the reason to remove RemovePackFile() without replacement ?
(And, if may Point that out: it is still being listed in the English help file)

Best regards & Keep up the good work!
Is this an artifact or should it be disposed of ?
User avatar
Flype
Addict
Addict
Posts: 1542
Joined: Tue Jul 22, 2003 5:02 pm
Location: In a long distant galaxy

Re: PureBasic 5.40 LTS beta 1 is out !

Post by Flype »

Hi team,

Very good features list. I'm particularly looking at HTTP new functions.
Some other stuff is very welcomed also. Thank you.

However, i found some problems
I'm not sure if it's a bug or faulty host on my side

Linux x64 version / XUbuntu

when calling GetURLPart() ; works well with PB5.31, not PB5.4x

or when calling ReceiveHTTPMemory("")

Code: Select all

/usr/bin/ld: can't find -lcurl
collect2: error: ld returned 1 exit status
No programming language is perfect. There is not even a single best language.
There are only languages well suited or perhaps poorly suited for particular purposes. Herbert Mayer
User avatar
the.weavster
Addict
Addict
Posts: 1576
Joined: Thu Jul 03, 2003 6:53 pm
Location: England

Re: PureBasic 5.40 LTS beta 1 is out !

Post by the.weavster »

netmaestro wrote:Stunning update!!!
+1

I'm particularly chuffed with the new CGI commands and the database enhancements.
Now I'm looking forward to seeing what's going to be in the next SpiderBasic update because the two are now genuinely complementary.
User avatar
mback2k
Enthusiast
Enthusiast
Posts: 257
Joined: Sun Dec 02, 2007 12:11 pm
Location: Germany

Re: PureBasic 5.40 LTS beta 1 is out !

Post by mback2k »

Thanks for the new release. Would you mind sharing some details about the HTTPS/TLS implementation? I guess it is very important to understand if PureBasic performs server certificate validation, e.g. using the system certificate store, etc. and which cipher suites are used. Does PureBasic use the Windows SChannel library for TLS (for SMTPS)? And does it use WinHTTP for HTTPS? The post above mentions curl, I guess that one is used on Linux/Mac OS X? Thanks in advance!
Polo
Addict
Addict
Posts: 2422
Joined: Tue May 06, 2003 5:07 pm
Location: UK

Re: PureBasic 5.40 LTS beta 1 is out !

Post by Polo »

Nice, thanks!!! :)
User avatar
minimy
Enthusiast
Enthusiast
Posts: 551
Joined: Mon Jul 08, 2013 8:43 pm
Location: off world

Re: PureBasic 5.40 LTS beta 1 is out !

Post by minimy »

Yeaaaah!! You´re the boss! Thanks for a lot of news in our veteran friend.. Old, but not obsolete! :mrgreen:
PB forever! :D
If translation=Error: reply="Sorry, Im Spanish": Endif
box_80
Enthusiast
Enthusiast
Posts: 115
Joined: Mon Sep 03, 2012 8:52 pm

Re: PureBasic 5.40 LTS beta 1 is out !

Post by box_80 »

Seeing a lot of cool features, thanks.
Post Reply