Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds

Tech News - Languages

202 Articles
article-image-git-2-19-0-released-better-git-grep-python-3-compatibility-git-p4
Savia Lobo
13 Sep 2018
3 min read
Save for later

Git 2.19.0 released with better git grep, Python 3 compatibility for git p4

Savia Lobo
13 Sep 2018
3 min read
Git project released Git 2.19 earlier this week (September 10th, 2018). Git 2.19 brings more Python 3 compatibility work for git p4, a rewritten git submodule now implemented in C. Git Instaweb works better with newer versions of Apache. It also has a git range-diff feature, new capabilities in git grep, branch sorting changes, and a variety of other additions. Features in Git 2.19 A new ‘git range-diff’ tool Developers previously used the git rebase to rewrite history and polish their commits before making them public. git diff shows the difference between the two end states, but it doesn’t provide information about any of the individual commits. This version includes git range-diff, a tool for comparing two sequences of commits, including changes to their order, commit messages, and the actual content changes they introduce. Improvements in ‘git grep’ In Git 2.19 you can now locate the first matching column of your query with git grep --column. git grep also learned the new --only-matching option. This is useful if you have a non-trivial regular expression and want to gather only the matching parts of your search. A new ‘auto’ option The content-transfer-encoding of the message "git send-email" sends out by default was 8bit, which can cause trouble when there is an overlong line to bust RFC 5322/2822 limit.  A new option 'auto' to automatically switch to quoted-printable when there is such a line in the payload has been introduced and is made the default. The branch.sort option and other sorting options The git branch command, like git tag (and their scriptable counterpart, git for-each-ref), takes a --sort option to let you order the results by a number of properties. To show branches in the order of most recent update, you could use git branch --sort=-authordate. However, if you always prefer that order, typing that sort option can get tiresome. This version introduces the branch.sort config to set the default ordering of git branch. By default, git branch sorts by refname, hence master is first and newest is last. The other sorting options include: --sort=numparent shows the best merges. --sort=refname sorts branches alphabetically by their name. --sort=upstream sorts branches by the remote from which they originate. Other improvements in Git 2.19 ‘git submodule foreach’ has been largely rewritten in C. ‘git diff --color-moved’ feature has further improvised. The userdiff pattern for .php has been updated. ‘git instaweb’ has been adjusted to run better with newer Apache on RedHat based distros. Preparatory code to later add json output for telemetry data has been added. Read the complete updates and improvements in the Git 2.19 release notes. Microsoft announces Azure DevOps, makes Azure pipelines available on GitHub Marketplace Packt’s GitHub portal hits 2,000 repositories GitHub parts ways with JQuery, adopts Vanilla JS for its frontend
Read more
  • 0
  • 0
  • 2492

article-image-python-comes-third-in-tiobe-popularity-index-for-the-first-time
Prasad Ramesh
10 Sep 2018
2 min read
Save for later

Python comes third in TIOBE popularity index for the first time

Prasad Ramesh
10 Sep 2018
2 min read
Python made it to the TIOBE index in the third position for the first time in its history. The TIOBE programming community index is a common measure of programming language popularity. It is created and maintained by the TIOBE company based in the Netherlands. The popularity in the index is calculated based on the number of search engine results for search queries with the name of the language. They consider searches from Google, Google Blogs, MSN, Yahoo!, Baidu, Wikipedia, and YouTube. The TIOBE index is updated once a month. Source: TIOBE Python is third behind Java and C. Python’s rating is 7.653 percent while Java had a rating of 17.436 percent. C was in the second place rated at 15.447 percent. Python moved above C++ to be placed third. C++ was third last month and now is in the fourth place this month, with a rating of 7.394 percent. Python has increasing ubiquity, being used in many research areas like AI and machine learning which are all the buzz today. The increasing popularity is not surprising as Python has versatile applications. AI and machine learning, software development, web development, scripting, scientific applications, and even games, you name it. Python is easy to install, learn, use, and deploy. The syntax is also very simple and beginner friendly. TIOBE states that this third place took a really took a long time. “At the beginning of the 1990s it entered the chart. Then it took another 10 years before it reached the TIOBE index top 10 for the first time. After that it slowly but surely approached the top 5 and eventually the top 3.“ Python has also been the language of the year in the index for the years 2007 and 2010. The current top 5 languages are Java, C, Python, C++, and Visual Basic .NET. To read more and to view the complete list of the index, visit the TIOBE website. Build a custom news feed with Python [Tutorial] Home Assistant: an open source Python home automation hub to rule all things smart Build botnet detectors using machine learning algorithms in Python [Tutorial]
Read more
  • 0
  • 0
  • 6643

article-image-ripgrep-0-10-0-released-with-pcre2-and-multi-line-search-support
Natasha Mathur
10 Sep 2018
2 min read
Save for later

Ripgrep 0.10.0 released with PCRE2 and multi-line search support

Natasha Mathur
10 Sep 2018
2 min read
The Ripgrep team released a minor version Ripgrep 0.10.0 last week. It explores features such as PCRE2 support, multi-line search and a JSON output format among other minor updates. Ripgrep is a command line search tool that recursively searches your current directory for a regex pattern while respecting your gitignore rules. It offers first class support on Windows, macOS, and Linux. Major Updates The minimum version which was required to compile Rust has been changed to track the latest stable version of Rust. The new minor versions will be using the current stable version of the Rust compile as its minimum supported version. Ripgrep 0.10.0 has now got libripgrep which helps with fast searching over arbitrary streams of data.  A new feature offering multi-line support has been added, which allows matching over multiple lines. There’s another new feature PCRE2 and JSON Lines format. The PCRE2 feature provides support for look-around and backreferences ( match the same text as previously matched by a capturing group ) and JSON lines format makes use of --json flag which helps print results in that format. Other changes A --one-file-system flag has been added to skip directories on different file systems. Two new minor features namely --sort and --sortr flag have been added for more sorting. --crlf flag is added in Ripgrep 0.10.0 to permit $ to work with carriage returns on Windows. A --null-data flag has been added to ripgrep 0.10.0 that makes ripgrep use NUL as a line terminator. --line-buffered and --block-buffered have been added for forcing a buffer strategy. A --pre-glob feature has been added for filtering files through the --pre flag. Bug Fixes A bug in ignore crate, where first path was treated as a symlink, has been fixed in ripgrep 0.10.0. Compile time and runtime CPU features have been added to --version output. ripgrep is more robust now when it comes to memory maps failing. For more information, check out the official ripgrep 0.10.0 release notes. Arduino now has a command line interface (CLI) Command Line Tools for DevOps Command-Line Tools
Read more
  • 0
  • 0
  • 2806

article-image-go-2-design-drafts-include-plans-for-better-error-handling-and-generics
Prasad Ramesh
29 Aug 2018
3 min read
Save for later

Go 2 design drafts include plans for better error handling and generics

Prasad Ramesh
29 Aug 2018
3 min read
In the annual Go user survey, the three top requests made by users for Go version 2 were better package management, error handling and the inclusion of generics. Following these requests, the Go 2 draft designs were shared yesterday to include error handling, error values, and adding generics. Note that these are not official proposals. The features, error handling and generics are in step 2 according to the Go release cycle, shown as follows. Source: Go Blog Yesterday, Google developer Russ Cox, gave a talk on design drafts for Golang 2. Go 2 draft designs were also previewed at Gophercon 2018. In his talk, he mentions that the current boilerplate contains too much code for error checks and that the error reporting is not precise enough. For example, an error while using os.Open in which the name of the file which cannot be opened, isn’t mentioned. As proper error reporting only adds to the code, most programmers don’t really bother with this despite knowing that such a practice may create confusion. The new idea, therefore, aims to add a check expression to shorten the checks while keeping them explicit. Cox also stresses on adding experience reports. These reports are difficult but necessary to implement new features. Experience reports turn abstract problems into concrete ones and are needed for changes to be implemented in Golang. They serve as a test case for evaluating a proposed solution and its effects on real-life use-cases. Regarding the inclusion of Generics, Cox mentions: “I've been examining generics recently, but I don't have in my mind a clear picture of the detailed, concrete problems that Go users need generics to solve. As a result, I can't answer a design question like whether to support generic methods, which is to say methods that are parameterized separately from the receiver. If we had a large set of real-world use cases, we could begin to answer a question like this by examining the significant ones.” Go 2 is not going to be a single release, but a sequence of releases adding features as and when they are ready. The approach is to first make features backward compatible to Go 1. Minor changes could be seen in Go 1 in a year or so. If there are no backward incompatible changes, Go 1.20 may be just declared as Go 2. The conversation for Go 2 has started, and there is a call for community help and contribution to converting the drafts into official proposals. Visit the Go page and the GitHub repository for more details. Why Golang is the fastest growing language on GitHub Golang 1.11 is here with modules and experimental WebAssembly port among other updates GoMobile: GoLang’s Foray into the Mobile World
Read more
  • 0
  • 0
  • 5826

article-image-splinter-0-9-0-the-popular-web-app-testing-tool-released
Melisha Dsouza
28 Aug 2018
2 min read
Save for later

Splinter 0.9.0, the popular web app testing tool, released!

Melisha Dsouza
28 Aug 2018
2 min read
Splinter, the open source tool for testing web applications using Python has now leveled up to Splinter 0.9.0. Browser actions such as visiting URLs and interacting with their items can be automated. Apart from providing a simple api, Splinter has multiple webdrivers including chrome webdriver, firefox webdriver, phantomjs webdriver, zopetest browser, and remote webdriver. It provides support to iframe, alert and executes javascript while working with both, ajax and async javascript. Two ways to install Splinter 0.9.0 Step 1: Install Python In order to install Splinter, you need to make sure that Python 2.7+  is installed. Step 2: Install Splinter There are two ways to install Splinter: Install a stable release For an official and almost bug-free version, use the terminal: $ [sudo] pip install splinter Install under-development source-code For splinter’s latest-and-greatest features and aren’t afraid of running under development code, run: $ git clone git://github.com/cobrateam/splinter.git $ cd splinter $ [sudo] python setup.py install Head over to the install guide for additional notes. Upgraded features in Splinter 0.9.0 Support for phantomjs is removed. With Chrome and Firefox headless, phantom is no longer needed. Users can now add custom options to the chrome browser. The bug related to element.find_by_text  stands resolved. When trying to do a contextual search for text, the result would include all matching text for the whole DOM instead of just those nodes that are children of the contextual node. Support was added for zope.testbrowser 5+, Flask 1+, selenium 3.14.0. Splinter can now handle webdriver StaleElementReferenceException. The lxml and cssselect has been updated  to 4.2.4  1.0.3 respectively. For a detailed explanation of features visitits  Github page. Visual Studio code July 2018 release, version 1.26 is out! OpenSSH 7.8 released! JDK 11 First Release Candidate (RC) is out with ZGC, Epsilon and more!  
Read more
  • 0
  • 0
  • 4814

article-image-jdk-11-first-release-candidate-rc-is-out-with-zgc-epsilon-and-more
Bhagyashree R
27 Aug 2018
3 min read
Save for later

JDK 11 First Release Candidate (RC) is out with ZGC, Epsilon and more!

Bhagyashree R
27 Aug 2018
3 min read
On Friday, Oracle released the JDK 11 first Release Candidate. It includes features such as nest-based access control, dynamic class-file constants, improved Aarch64 intrinsics, and more. The general availability of the final release of JDK 11 is scheduled for next month on the 25th. Every six months, in June and December, the community initiates the release cycle for the next JDK feature release. The work proceeds over the next three months in three phases: Rampdown Phase One (RDP 1), Rampdown Phase Two (RDP 2), and Release-Candidate Phase (RC).The durations of the phases for JDK 11 are four weeks for RDP 1, three weeks for RDP 2, and five weeks for RC. What is new in JDK 11 RC 1.0 ? Nest-based access control Nest is introduced to allow classes that are a logically part of the same code entity, but are compiled to distinct class files, access each other’s private members. Dynamic class-file constants To support a new constant-pool form named, CONSTANT_Dynamic, Java class-file format is extended. Loading this pool will delegate creation to a bootstrap method, just as linking an invokedynamic call site delegates linkage to a bootstrap method. Improvements in Aarch64 intrinsics Intrinsics are used to improve performance by leveraging CPU architecture-specific assembly code for a given method, instead of a generic Java code. The existing string and array intrinsics are improved and new intrinsics are implemented for the java.lang.Math package on AArch64 processors: sin (sine trigonometric function) cos (cosine trigonometric function) log (logarithm of a number) Epsilon A new garbage collector named, Epsilon is introduced that handles memory allocation but does not implement any actual memory reclamation mechanism. The JVM will shut down once the available Java heap is exhausted. Java EE and CORBA modules removed These modules are removed from the Java SE Platform and the JDK. Earlier, they were deprecated in the Java SE 9, indicating their removal in a future release. HTTP Client (Standard) The HTTP Client API, introduced as an incubating API in JDK 9 and JDK 10 is standardized. This API received a number of rounds of feedback that resulted in significant improvements. The module name and the package name of the standard API will be java.net.http. Local-variable syntax for lambda parameters When declaring the formal parameters of implicitly typed lambda expressions, the use of ‘var’ is allowed. Now the following expression: (var x, var y) -> x.process(y) is equivalent to: (x, y) -> x.process(y) Unicode 10 The existing platform APIs will support version 10.0 of the Unicode Standard. It is supported in the following classes: In java.lang: Character and String In java.awt.font: NumericShaper In java.text: Bidi, BreakIterator, and Normalizer New Flight Recorder Flight Recorder, a low-overhead data collection framework is provided for troubleshooting Java applications and the HotSpot JVM. Addition of ChaCha20 and Poly1305 cryptographic algorithms An implementation of the ChaCha20 and ChaCha20-Poly1305 ciphers as specified in RFC 7539 are added. ChaCha20 is a relatively new stream cipher that can replace the older, insecure RC4 stream cipher. ZGC (Experimental) The Z Garbage Collector, also known as ZGC, is a scalable low-latency garbage collector. ZGC is a concurrent, single-generation, region-based, NUMA-aware, compacting collector. To know more about these updates and improvements in detail, head over to its official website, OpenJDK. JavaFX 11 to release soon, announces the Gluon team State of OpenJDK: Past, Present and Future with Oracle Mark Reinhold on the evolution of Java platform and OpenJDK  
Read more
  • 0
  • 0
  • 6628
Unlock access to the largest independent learning library in Tech for FREE!
Get unlimited access to 7500+ expert-authored eBooks and video courses covering every tech area you can think of.
Renews at €18.99/month. Cancel anytime
article-image-openssh-7-8-released
Melisha Dsouza
27 Aug 2018
4 min read
Save for later

OpenSSH 7.8 released!

Melisha Dsouza
27 Aug 2018
4 min read
OpenSSH 7.8 base source code was released on August 24, 2018. It includes many new features such as a fix for the username enumeration vulnerability, changes to the default format for the private key file, and many more. Additionally, support for running ssh setuid root has been removed, and a couple of new signature algorithms have been added. The base source code is designed specifically for OpenBSD. The aim was to make the code simple, clean, minimal, and auditable. This release will be available from the mirrors listed at http://www.openssh.com/ shortly. Let’s take a look at the features that developers can expect in this new version of OpenSSH Changes that may affect existing configurations ssh-keygen(1): Write OpenSSH format private keys by default instead of using OpenSSL's PEM format. This offers better protection against offline password guessing and supports key comments in private keys. sshd(8): Internal support for S/Key multiple factor authentication is removed. S/Key may still be used via PAM or BSD auth. ssh(1): Vestigal support for running ssh(1) as setuid is removed. sshd(8): The semantics of PubkeyAcceptedKeyTypes and HostbasedAcceptedKeyTypes now specify signature algorithms that are accepted for their respective authentication mechanism. This matters when using the RSA/SHA2 signature algorithms "rsa-sha2-256", "rsa-sha2-512" and their certificate counterparts. Configurations that override these options but do not use these algorithm names may cause unexpected authentication failures. sshd(8): The precedence of session environment variables has changed. ~/.ssh/environment and environment="..." options in authorized_keys files can no longer override SSH_* variables set implicitly by sshd. ssh(1)/sshd(8): The default IPQoS used by ssh/sshd has changed.Interactive traffic will use  DSCP AF21and CS1 will be used  for bulk. For a detailed understanding, head over to the commit message: https://cvsweb.openbsd.org/src/usr.bin/ssh/readconf.c#rev1.28 What's new in OpenSSH 7.8 This  bugfix release has a couple of New Features in store for developers. Let’s take a look at some of the important ones. New signature algorithms "rsa-sha2-256-cert- v01@openssh.com" and "rsa-sha2-512-cert-v01@openssh.com" to  explicitly force use of RSA/SHA2 signatures in authentication. Read more at  ssh(1)/sshd(8). Some countermeasures are added against timing attacks used for account validation/enumeration. sshd will impart a minimum time or each failed authentication attempt consisting of a global 5ms minimum plus an additional per-user 0-4ms delay derived from a host secret. Fine more information at sshd(8). In sshd(8), you can add a SetEnv directive to explicitly specify environment variables in sshd_config by an administrator. Variables set by SetEnv override the default and client-specified Environment. In ssh(1), you can add a SetEnv directive to request that the server sets an environment variable in the session. Similar to the existing SendEnv option, these variables are set subject to server Configuration. Clear environment variables previously marked for sending to the server by "SendEnv -PATTERN" Bug Fixes introduced in this new version In the sshd(8), users can avoid observable differences in request parsing that could be used to determine whether a target user is valid. They can also fix failures to read authorized_keys caused by faulty supplemental group caching. Failures can be fixed to read authorized_keys caused by faulty supplemental group caching. The relax checking of authorized_keys environment="..." options to allow underscores in variable names  (regression introduced in 7.7) Some memory leaks in the ssh(1)/sshd(8) have been fixed. The SSH2_MSG_DEBUG messages for Twisted Conch clients in the ssh(1)/sshd(8) have also been disabled. Tunnel forwarding has also been fixed. In ssh(1), you can now fix a pwent clobber (introduced in openssh-7.7) that could occur during key loading, manifesting as crash on some platforms. To get a detailed overview of the features and changes introduced in portability and checksums in this new release, head over to the official release notes. JavaFX 11 to release soon, announces the Gluon team Gitlab 11.2 releases with preview changes in Web IDE, Android Project Import and more Bodhi Linux 5.0.0 released with updated Ubuntu core 18.04 and a modern look
Read more
  • 0
  • 0
  • 8204

article-image-golang-1-11-is-here-with-modules-and-experimental-webassembly-port-among-other-updates
Natasha Mathur
27 Aug 2018
5 min read
Save for later

Golang 1.11 is here with modules and experimental WebAssembly port among other updates

Natasha Mathur
27 Aug 2018
5 min read
Golang 1.11 is here with modules and experimental WebAssembly port among other updates The Golang team released Golang 1.11 rc1 two weeks back, and now the much awaited Golang 1.11 is here. Golang 1.11, released last Friday, comes with changes and improvements to the toolchain, runtime, libraries, preliminary support for “modules”, and experimental port to WebAssembly. Golang is a modern programming language by Google, which was developed back in 2009 for application development. It’s simple syntax, concurrency support, and fast nature makes it one of the fastest growing languages in the software industry. Let’s now explore the new features in Golang 1.11. Ports Go 1.11 adds an experimental port to WebAssembly ( js/wasm ) along with other changes. Web Assembly Go 1.11 adds new GOOS value “js” and GOARCH value “wasm” to  WebAssembly. Go files named *_js.go or *_wasm.go will now be ignored by Go tools except for times when GOOS/GOARCH values are being used. The GOARCH name “wasm” is the official abbreviation of WebAssembly. The GOOS name “js” is due to the host environments like web browsers and Node.js, that executes the WebAssembly bytecode. Both of these host environments use JavaScript to embed WebAssembly. RISC-V GOARCH values reserved The main Go compiler does not provide support for the RISC-V architecture. Go 1.11 reserves the GOARCH values namely "riscv" and "riscv64" by Gccgo that supports RISC-V. This means that Go files named *_riscv.go will be ignored by Go tools except for cases when those GOOS/GOARCH values are being used. Other changes Go 1.11 now needs OpenBSD 6.2 or later, macOS 10.10 Yosemite or later, or Windows 7 or later. Any support for previous versions of these operating systems have been deprecated. It also offers support for the upcoming OpenBSD 6.4 release. With changes in the OpenBSD kernel, you won’t be able to run older versions of Go on OpenBSD 6.4. With Go 1.11, the new environment variable settings have been added for 64-bit MIPS systems, namely, GOMIPS64=hardfloat (the default) and GOMIPS64=softfloat. These enable you to decide whether to use hardware instructions or software emulation for floating-point computations. Go now uses a more efficient software floating point interface on soft float ARM systems (GOARM = 5). There is no need of a linux kernel configured with KUSER_HELPERS now on ARMv7. Toolchain There are also fixes made in Modules, packages, and debugging in Golang 1.11. Modules There’s now preliminary support added for a new experimental concept called “modules”, in Golang 1.11. This is an alternative to GOPATH with integrated support for versioning and package distribution. With the help of modules, developers are no longer limited to working inside GOPATH. Package loading There’s a new package, the golang.org/x/tools/go/packages that offers a simple API for locating and loading Go source code packages. It’s not yet part of the standard library but it effectively replaces the go/build package for many tasks. Build cache requirement Go 1.11 will be the last release which offers support for setting the environment variable GOCACHE=off ( to disable the build cache ), that was introduced in Go 1.10. The compiler toolchain now offers support for column information in line directives. Improved debugging The compiler in Go 1.11 now offers improved debugging for optimized binaries which includes variable location information, line numbers, and breakpoint locations. This makes it possible to debug binaries compiled without -N -l. There’s also experimental support added for calling Go functions from within a debugger. Compiler Toolchain Golang 1.11 offers support for column information in line directives. Also, a new package export data format is introduced which is transparent to end users, except for speeding up build times for large Go projects. Runtime Runtime in Go 1.11 now makes use of a sparse heap layout. This ensures that there is no longer a limit to the size of the Go heap as the limit was 512GiB earlier. It also provides fixing of rare "address space conflict" failures in mixed Go/C binaries or binaries compiled with -race. Library changes There are various minor updates and changes to the core library in Golang 1.11. Crypto: Crypto operations such as ecdsa.Sign, rsa.EncryptPKCS1v15 and rsa.GenerateKey, now randomly read an extra byte to ensure that tests don't rely on internal behavior. debug/elf: Constants such as ELFOSABI and EM have been added. encoding/asn1: There is now support for "private" class annotations for fields in Marshal and Unmarshal. image/gif: There is support for non-looping animated GIFs. They are denoted by having a LoopCount of -1. math/big: With Golang 1.11, ModInverse now returns nil when g and n are not relatively prime. Apart from these major updates, there are many other changes in Golang 1.11. To get more information, be sure to check the official Golang 1.11 release notes. Writing test functions in Golang [Tutorial] How Concurrency and Parallelism works in Golang [Tutorial] GoMobile: GoLang’s Foray into the Mobile World  
Read more
  • 0
  • 0
  • 6162

article-image-jep-325-revamped-switch-statements-that-can-also-be-expressions-proposed-for-java-12
Prasad Ramesh
21 Aug 2018
3 min read
Save for later

JEP 325: Revamped switch statements that can also be expressions proposed for Java 12

Prasad Ramesh
21 Aug 2018
3 min read
Java is preparing to support pattern matching, part of which is revamping the switch statement. The changes are going to allow the switch statement to be used as both statements and as an expression. The changes to the switch statement will simplify everyday coding. It will also pave the way for the use of pattern matching in switch. The current Java switch statement is similar to the ones in languages such as C and C++. It supports fall-through semantics by default. This traditional control flow is often useful for writing low-level code but is error-prone in switch statements used in higher-level code. Brian Goetz, architect at Oracle has proposed to add a new simplified form, with new "case L ->" switch labels in addition to traditional switch blocks. On label match, only the statement or expression to the right of an arrow label is executed. For example, consider the following method: static void howMany(int k) {    switch (k) {        case 1 -> System.out.println("one");        case 2 -> System.out.println("two");        case 3 -> System.out.println("many");    } } On calling the function on these values: howMany(1); howMany(2); howMany(3); This is the output: one two many A new form of switch label, written "case L ->" is proposed to be added. This is an effort to imply that only the code to the right of the label is to be executed if the label is matched. Like a switch statement, a switch expression can also use a traditional switch block with "case L:" switch labels. Most switch expressions have only one expression to the right of the "case L ->" switch label. When a full block is needed, the break statement is extended to take an argument. The cases of a switch expression must contain a matching switch label for any possible value. In practice, this means that a default clause is required. An enum switch expression covers all known cases. In this case, a default clause can be inserted by the compiler indicating that the enum definition has changed between compile-time and runtime. This is done manually by developers today, but having the compiler insert is less intrusive. Also, a switch expression must execute normally with a value or throw an exception. This has a number of consequences like the compiler checking every switch label. Another consequence is that the control statements like break, return and continue, not being able to jump through a switch expression. For more information visit the official OpenJDK post. No more free Java SE 8 updates for commercial use after January 2019 Dagger 2.17, a dependency injection framework for Java and Android, is now out! Build Java EE containers using Docker [Tutorial]
Read more
  • 0
  • 0
  • 4163

article-image-microsofts-net-core-2-1-now-powers-bing-com
Melisha Dsouza
21 Aug 2018
4 min read
Save for later

Microsoft’s .NET Core 2.1 now powers Bing.com

Melisha Dsouza
21 Aug 2018
4 min read
Microsoft is ever striving to make its products run better. They can add yet another accomplishment to their list as Microsoft’s cloud service search engine, Bing is now running fully on .NET Core 2.1, as announced by the .NET engineering team in their blog yesterday. .NET Core is the slimmed down and cross-platform version of Microsoft’s .NET managed common language runtime. Since Bing runs on thousands of servers spanning many data centers across the globe, .NET Core will serve as the perfect platform for it to function on. Why did Bing migrate to .NET Core 2.1? Bing has always run on the .NET Framework, but has been able to move to .NET Core 2.1 after some recent API additions. Let’s take a look at the main reasons for Bing.com’s migration to .NET Core. 1. Performance i.e. serving latency .NET Core 2.1 has led to an improvement in performance in virtually all areas of the runtime and libraries. The internal server latency over the last few months shows a striking 34% improvement. Check out the graph for a clear picture!     Souce: blog.msdn.microsoft.com The following changes in .NET Core 2.1 are the reasons why the workload and performance has greatly improved- #1 Vectorization of string.Equals & string.IndexOf/LastIndexOf HTML rendering and manipulation are string-heavy workloads. Vectorization of String comparisons and indexing operations (major components of string slicing) is the biggest contributor to the performance improvement. You can find more information on this on the github page for  Vectorization of string.Equals and string.IndexOf/LastIndexOf #2 Devirtualization Support for EqualityComparer<T>.Default One of .NET core’s major software components is a heavy user of Dictionary<int/long, V>, which indirectly benefits from the intrinsic recognition work that was done in the JIT to make Dictionary<K, V> amenable to that optimization.  Head over to the github page for more clarity on why this feature empowers .NET Core 2.1 #3 Software Write Watch for Concurrent GC This led to a reduction in CPU usage. The implementation relies on a JIT Write Barrier, which instinctively increases the cost of a reference store, but that cost is amortized and not noticed in the workload. #4 Methods with calli are now inline-able ldftn + calli  are used in lieu of delegates (which incur an object allocation) in performance-critical pieces of code where there is a need to call a managed method indirectly. This change allowed method bodies with a calli instruction to be eligible for inlining. The github page provides more insight on this subject. #5 Improve performance of string.IndexOfAny for 2 & 3 char searches A common operation in a front-end stack is search for ‘:’, ‘/’, ‘/’ in a string to delimit portions of a URL. Check out this special-casing improvement that was beneficial throughout the codebase on the github page. 2. Runtime Agility The ability to have an xcopy version of the runtime inside their application denotes that they can adopt newer versions of the runtime at a much faster pace. The Continuous integration (CI) pipeline is run with .NET Core’s daily CI and it builds testing functionality and performance all the way through the release. 3. ReadyToRun Images Managed applications usually can have poor startup performance as methods first have to be JIT compiled to machine code. .NET Framework has a precompilation technology, NGEN. On .NET Core, the crossgen tool allows the code to be precompiled as a pre-deployment step, such as in the build lab, and the images deployed to production are Ready To Run! This feature was not supported on the previous  .NET implementation. The .NET Core team is striving to provide Bing.com users fast results. The latest software and technologies used by their developers will ensure that .NET Core will not fail Bing.com! Read the detailed overview of the article on Microsoft's blog. Say hello to FASTER: a new key-value store for large state management by Microsoft Microsoft Azure’s new governance DApp: An enterprise blockchain without mining .NET Core completes move to the new compiler – RyuJIT
Read more
  • 0
  • 0
  • 12563
article-image-rust-language-server-rls-1-0-releases
Fatema Patrawala
21 Aug 2018
2 min read
Save for later

Rust Language Server, RLS 1.0 releases with code intelligence, syntax highlighting and more

Fatema Patrawala
21 Aug 2018
2 min read
The Rust Language Server 0.130.5 announces its first 1.0 release candidate. The 1.0 release is available on the nightly and beta version and will be available with stable Rust version from 3rd September this year. RLS 1.0 will be able to handle most small and medium sized projects with certain limitations and improvements. Major highlights of this release are syntax highlighting, syntactic code completion and code intelligence.To easily install RLS you can install an extension of your favorite editor, for example: Visual Studio Code Atom Sublime Text Eclipse What’s new in RLS 1.0 release Syntax highlighting Each editor does its own syntax highlighting Code completion Code completion is syntactic, performed by Racer. Because it is syntactic there are many instances where it is incomplete or incorrect. Errors and warnings Errors and other diagnostics are displayed inline. Exactly how the errors are presented depends on the editor. Formatting By Rustfmt (which is also at the 1.0 release candidate stage). Clippy Clippy is installed as part of the RLS. You can turn it on with a setting in your editor or with the usual crate attribute. Code intelligence The RLS can do the following: type and docs on hover goto definition find all references find all implementations for traits and concrete types find all symbols in the file/project renaming (this will not work where a renaming would cause an error, such as where the field initialisation syntax is used) change glob imports to list imports For more information visit the release notes page. Rust 2018 Edition Preview 2 is here! Rust and Web Assembly announce ‘wasm-bindgen 0.2.16’ and the first release of ‘wasm-bindgen-futures’ Rust 1.28 is here with global allocators, nonZero types and more
Read more
  • 0
  • 0
  • 5035

article-image-no-more-free-java-se-8-updates-for-commercial-use-after-january-2019
Prasad Ramesh
20 Aug 2018
2 min read
Save for later

No more free Java SE 8 updates for commercial use after January 2019

Prasad Ramesh
20 Aug 2018
2 min read
Oracle owned Java will no longer provide free public updates of Java SE 8 for commercial use after January 2019. This move is a part of their long term support (LTS) plan. However, for individual personal use the public updates for Oracle Java SE 8 will be available at least till December 2020. Borrowing ideas from Linux releases, Oracle Java releases will now follow LTS. The bi yearly updates will now have minor updates. One of the releases being termed as LTS and Oracle will provide long term support for it (3 years). Other releases will cease getting support when the next version is released. If you are using Java for personal use individually, you will have the same access to Oracle Java SE 8 updates till end of 2020. In most cases, the Java-based applications run on your PCs are licensed by a company other than Oracle. For example, games developed by gaming companies. You won’t have access to public updates beyond the date mentioned, it depends on the gaming company on how they plan to provide application support. Developers are recommended to view Oracle’s release roadmap for Java SE 8 and other versions. Accordingly, you can take action to support your applications. The next LTS version, Java 11 is set to roll out in September 2018. Here is the Oracle Java SE Support Roadmap. Release GA Date Premier Support Until Notification Extended Support Until Sustaining Support 6 December 2006 December 2015 December 2018 Indefinite 7 July 2011 July 2019 July 2022 Indefinite 8 March 2014 March 2022 March 2025 Indefinite 9 (non‑LTS) September 2017 March 2018 Not Available Indefinite 10 (18.3^)(non‑LTS) March 2018 September 2018 Not Available Indefinite 11 (18.9^ LTS) September 2018 September 2023 September 2026 Indefinite 12 (19.3^ non‑LTS) March 2019 September 2019 Not Available Indefinite The roadmap for web deployment and Java FX is different and is listed on their website. This video explains the LTS release model for Java, for more information, visit the official update. Mark Reinhold on the evolution of Java platform and OpenJDK Build Java EE containers using Docker [Tutorial] 5 Things you need to know about Java 10
Read more
  • 0
  • 0
  • 18733

article-image-what-the-ieee-2018-programming-languages-survey-reveals-to-us
Savia Lobo
19 Aug 2018
7 min read
Save for later

What the IEEE 2018 programming languages survey reveals to us

Savia Lobo
19 Aug 2018
7 min read
Programming languages are the foundations of all the existing technology that we are surrounded with. Developers, tech enthusiasts, and others keep themselves updated with the latest programming languages to be abreast with the advancements happening within each of it. Popular survey websites such as TIOBE, Redmonk, StackOverflow, IEEE spectrum, etc. help people to know about the trending top programming languages and where their favorite language stands. Out of these, the IEEE spectrum and StackOverflow showcase their ranking surveys annually. Whereas TIOBE does it every month and Redmonk does it semi-annually. From the two annual survey providers, Stack Overflow takes in surveys from 56,033 coders in 173 countries  whereas IEEE spectrum’s survey synthesizes rankings from 10 sources including Google search of “X programming” Google Trends Twitter GitHub StackOverflow Reddit Hacker News CareerBuilder Dice IEEE Xplore Digital Library The IEEE spectrum aggregates different kinds of statistical data with a view to generate the most reliable ranking. It also gives the most personalized ranking. The interactive interface allows readers to filter by search trends, job trends, or open source community trends. You can even modify the weighting of each dimension, enabling an extremely personalized ranking. Of the five popular language ranking surveys and our own Packt’s Skill Up survey 2018, the top 10 programming languages for this year include, Top 10 languages across popular surveys     Stack Overflow Redmonk TIOBE IEEE Spectrum Packt Skill Up Survey JavaScript JavaScript Java Python Java HTML Java C C++ JavaScript CSS Python C++ C Python SQL PHP Python Java C# Java C# Visual Basic C# SQL Bash/Shell C++ C# PHP C++ Python CSS PHP R C C# Ruby JavaScript JavaScript PHP PHP C SQL Go Swift C++ Swift Assembly Assembly Go Our Takeaways from IEEE survey What was obvious Python in the top 3: Python has been bagging the top position at the IEEE spectrum for two years in continuation now. It is the easiest programming language of all with an easy-going syntax. However, IEEE mentions the reason for Python to be at the zenith is because it is now listed as an embedded language. Go in the top 10 list: Google’s Go has risen from the 7th position last year to the 5th this year. Its speed, simplicity, reliability, cross-platform ability, native concurrency, easy deployment makes it the go-to cloud-native language for developers. Thus, making it the fastest growing programming language. Java, C++, C, C# in the top 5: These legendary languages are still in the top 5 due to its large scale industry-wide adoption and an established community. Also, many professional developers have been working on these languages since years and find it difficult to migrate to any new programming language making these stay at the top. R language drops down a notch: The language for statistics and big data, R has stepped down from its 6th position to a 7th position. R’s decline could be due to the popularity of Python due to the high-quality Python libraries for both statistics and machine learning. This makes statistics and big data more flexible to turn to Python than the more specialized R. What was surprising? Kotlin language not included in the list: The recently popular programming language for Android development is missing from IEEE’s survey list. Many developers use Kotlin instead of Python and Java for internal app development (console apps, OpenGL-apps, threaded socket servers, etc). Kotlin also eases porting of code from Python to Kotlin. Many promising languages missing from the IEEE list: Languages such as Typescript, Dart are missing. Typescript is the superset of JavaScript, which lacks a type system. The introduction of Typescript adds optional static typing to Javascript. Similarly, Dart is the also a useful language and can be used to program front-end applications. It is easy to use with a non-existent learning curve. Matlab and Assembly languages maintain their positions: Matlab is used for scientific computing and mathematical processing. First released in 1984, it is one of the oldest languages after Assembly still maintaining the 11th position in this list. It is widely used in Academics and research and hence is never outdated. Similarly, Assembly, the oldest form of programming, at the 10th position is still relevant to many developers. This is because it supports fast code with the absence of a compiler and is the best bet for machine level programming. Javascript not in the top 5: Being one of the dominant languages on the web front-end development, JavaScript is at the 8th position in IEEE’s list. This must be because other languages such as TypeScript and WebAssembly are providing an easy way to C/C++ developers What we are skeptical about/don’t agree with PHP might not be in the top 10: PHP is one of the most popular languages for server-side programming. Other programming languages such as Python and Ruby on Rails are competing with PHP by providing a much more simple, useful and powerful coding syntax and tools in the same domain as PHP. Ruby might drop down a few more notches: Although Ruby was the first full-stack language to be used on front and back-end development, it is difficult to learn. Integrating third-party libraries on ruby is also difficult which makes it non-flexible. As there are several options in the market today, I am skeptical Ruby will maintain its current position. Is Swift dropping from its position: Swift programming language was built by Apple Inc. for iOS, macOS, watchOS, and tvOS. Being an Apple-only development environment, developers are moving to multi-platform mobile apps such as Microsoft’s Xamarin, Apache Cordova, and Ionic. This may affect Swift’s user community. Limitations of the IEEE survey The IEEE Spectrum 2018 survey included 47 programming languages ranging from the most widely adopted to the least. However, not all the programming languages were a part of this list. Current popular languages such as Kotlin, Dart, TypeScript, WebAssembly and some others were missing from the list. As per some comments on the IEEE blog, IEEE uses the languages listed in Github. On Github, Visual basic is the common name used for both vb.net and Visual Basic. Also, some languages present in the other surveys are not present in the IEEE survey. For instance, the TIOBE index has PL/SQL at the 20th position. However, the IEEE survey has not mentioned about it. One more limitation it had was, it showed completely different results on different browsers, which Stephen Cass from IEEE spectrum said, “ I'd say it's due to variations in how JQuery/JavaScript is implemented in the different browsers: under the hood, the TPL uses a lot of floating point math, so what you are seeing could be due to differences in precision/rounding, et cetera. Ultimately, I suspect the solution will be to calculate the rankings completely server-side: the underlying code for the TPL is five years old, so we were thinking of overhauling it anyway, and this certainly puts some weight behind that.” Stephen further added, “I should add that we built the TPL primarily using Chrome, so our canonical version of the rankings is the one you see in that browser.” Read more about the other programming languages by IEEE Spectrum in the IEEE blog post Rust 1.28 is here with global allocators, nonZero types and more Racket v7.0 is out with overhauled internals, updates to DrRacket, TypedRacket among others Grain: A new functional programming language that compiles to Webassembly
Read more
  • 0
  • 0
  • 7936
article-image-golang-1-11-rc1-is-here-with-experimental-port-for-webassembly
Natasha Mathur
17 Aug 2018
3 min read
Save for later

Golang 1.11 rc1 is here with experimental port for WebAssembly!

Natasha Mathur
17 Aug 2018
3 min read
Golang team released Golang 1.11 rc1 version, earlier this week. The latest release explores features like web assembly (js/wasm ), preliminary support for modules and improved support for debuggers among others. Golang is currently one of the fastest growing programming languages in the software industry. Golang’s easy syntax, concurrency, and fast nature are few of the reasons for its popularity. It is a modern programming language, created by Google back in 2009 for the 21st-century application development. Let’s have a look at the key features that come with Golang 1.11 rc1. WebAssembly ( js/wasm) WebAssembly is different in the sense that it is not processed by a CPU directly, but instead, it is an intermediate representation which is compiled to actual machine code by the WebAssembly runtime environment. Now, Go 1.11 rc1 has added an experimental port to WebAssembly (js/wasm). Go programs used to compile to only one WebAssembly module. These modules include the Go runtime for goroutine scheduling, garbage collection, maps, etc. Because of this, the resulting size would be around 2 MB, or 500 KB compressed. Go programs can call into JavaScript with the help of new experimental syscall/js package. Now, with new GOOS value "js" and GOARCH value "wasm" added to the web assembly, Go files named *_js.go or *_wasm.go will now be ignored by Go tools except for cases when GOOS/GOARCH values are being used. The GOARCH name "wasm" is the official abbreviation of WebAssembly. The GOOS name "js" is due to the host environment that executes WebAssembly bytecode are web browsers and Node.js, both of which use JavaScript to embed WebAssembly. Preliminary support for modules Go 1.11 rc1 offers preliminary support for a new concept called “modules,” which is an alternative to GOPATH with integrated support for versioning and package distribution. With modules, developers are not limited to working inside GOPATH. Also, the version dependency information is explicit yet lightweight, and builds are more reliable. Improved support for debuggers The compiler in Go 1.11 rc1 now produces significantly accurate debug information for optimized binaries. This includes variable location information, line numbers, and breakpoint locations. Due to this, it is easier to debug binaries compiled without -N -l. There are still few limitations to the quality of the debug information which will improve with the future releases. DWARF sections have been compressed by default. This is due to the accurate debug information produced by the compiler. This is transparent to most ELF tools (like debuggers on Linux and *BSD) and is supported by the Delve debugger on all platforms.   Other changes Many direct system calls have been removed from the macOS runtime. Go 1.11 binaries are now less likely to break on upgrading macOS version because system calls are made through the proper channel (libc). Go 1.11 is expected to be released later this month. For more information, check out the official release notes. Writing test functions in Golang [Tutorial] How Concurrency and Parallelism works in Golang [Tutorial] GoMobile: GoLang’s Foray into the Mobile World
Read more
  • 0
  • 0
  • 6330

article-image-michael-barr-releases-embedded-c-coding-standards
Prasad Ramesh
17 Aug 2018
4 min read
Save for later

Michael Barr releases embedded C coding standards

Prasad Ramesh
17 Aug 2018
4 min read
Every C programmer has ideas about writing better C code. Comment first, agile, use this compiler etc. The Barr Group recently released a coding standards guideline for embedded C, which is also available as a freely downloadable ebook. The guidelines are grouped rules that fall under 8 broad categories (general, comments, white space, module, data type, procedure, variable and statements). Michael Barr is the CTO and co-founder of Barr Group. He has a Masters in electrical engineering, was an adjunct professor in electrical engineering/computer science and founded a company called Netrino and the Barr group for embedded systems consulting. He was also the Editor-in-Chief of the Embedded Systems Programming magazine. He has decades of experience so this should prove to be a great reference guide. What are these C guidelines about? C is pretty open-ended and leaves a lot of space of misuse. That is, a lot of bad code can be written in C. Any programming language can’t really prevent bad code, people have different approaches, some less efficient than the others. In the guidelines, Barr lists ways to change habits while coding. He states in his guideline book “The reliability, readability, efficiency, and sometimes portability of source code is more important than programmer convenience.” His also talks about MISRA C, the 20-year-old guideline created to promote more reliable programming. MISRA still is the gold standard for many embedded programmers. But MISRA avoids many issues of style, indentation, naming conventions, casings, and so on. But Barr does not shy away from any of that. It’s good to follow rules It isn’t uncommon for programmers to overlook the simple stuff. For example, they don’t bother with using braces for simple statements just because the language allows you to do so. Rule 1.3 states that all blocks however trivial should be enclosed in braces. The reasoning is “There is considerable risk associated with the presence of empty statements and single statements that are not surrounded by braces. Code constructs like this are often associated with bugs when nearby code is changed or commented out. This risk is entirely eliminated by the consistent use of braces. The placement of the left brace on the following line allows for easy visual checking for the corresponding right brace.” The employer owns the software/code you write. The employer would naturally expect you to follow the best known industry standards for the code to be least buggy and maintainable as possible. In addition, the C language is also not standard throughout, different compilers can produce different runtimes from the same code. This happens even if your code is clean and adhering to all ISO standards. Write legible code The code you write will most likely be used in the future. A short but dense code block can make you feel clever but will lack legibility. We are way past the times to bother about extra lines of code or comments taking up floppy disk space. Write for readability, comment generously, indent your loops and compound statements. Many seasoned programmers may already know or practice many of the rules stated in the book. But nonetheless it can serve as a really good reference guide for beginners and veterans alike. There are eight sections of rules with subsections in them. These were just some of the ideas presented in the guidelines, you can get the free PDF download or and if your prefer, the paperback version is available on Amazon. The 5 most popular programming languages in 2018 Polymorphism and type-pattern matching in Python [Tutorial] Qml.Net: A new C# library for cross-platform .NET GUI development
Read more
  • 0
  • 0
  • 7701